diff options
| author | Scott Cranfill <scott.cranfill@cfpb.gov> | 2020-05-20 13:11:30 -0400 |
|---|---|---|
| committer | Mariusz Felisiak <felisiak.mariusz@gmail.com> | 2020-05-27 12:32:56 +0200 |
| commit | 62f1655a64795d055f72e53557fb8404c5430963 (patch) | |
| tree | 5238b3662f872afa25b70279359f9caf744b8b8f /js_tests | |
| parent | 922ff51f5ac34205f454d7b5786cef57f32b6ca3 (diff) | |
Fixed #11157 -- Stopped removing stop words in admin's prepopulated_fields.
Co-Authored-By: Andy Chosak <andy@chosak.org>
Diffstat (limited to 'js_tests')
| -rw-r--r-- | js_tests/admin/URLify.test.js | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/js_tests/admin/URLify.test.js b/js_tests/admin/URLify.test.js index 4ff706be37..471f2fbf05 100644 --- a/js_tests/admin/URLify.test.js +++ b/js_tests/admin/URLify.test.js @@ -7,8 +7,8 @@ QUnit.test('empty string', function(assert) { assert.strictEqual(URLify('', 8, true), ''); }); -QUnit.test('strip nonessential words', function(assert) { - assert.strictEqual(URLify('the D is silent', 8, true), 'd-silent'); +QUnit.test('preserve nonessential words', function(assert) { + assert.strictEqual(URLify('the D is silent', 15, true), 'the-d-is-silent'); }); QUnit.test('strip non-URL characters', function(assert) { @@ -23,7 +23,6 @@ QUnit.test('trim trailing hyphens', function(assert) { assert.strictEqual(URLify('D silent always', 9, true), 'd-silent'); }); -QUnit.test('do not remove English words if the string contains non-ASCII', function(assert) { - // If removing English words wasn't skipped, the last 'a' would be removed. +QUnit.test('non-ASCII string', function(assert) { assert.strictEqual(URLify('Kaupa-miða', 255, true), 'kaupa-miða'); }); |
