Fixed "truncate a string" test that was preventing users from completing the challenge

This commit is contained in:
Nathan Leniz
2015-02-13 15:05:53 -05:00
parent a0427b3e18
commit 01cddba50d

View File

@ -169,7 +169,6 @@
"challengeEntryPoint":"truncate('A-tisket a-tasket A green and yellow basket', 11);", "challengeEntryPoint":"truncate('A-tisket a-tasket A green and yellow basket', 11);",
"challengeSeed":"function truncate(str, num) {\n // Clear out that junk in your trunc\r\n return str;\r\n}", "challengeSeed":"function truncate(str, num) {\n // Clear out that junk in your trunc\r\n return str;\r\n}",
"tests": [ "tests": [
"var string = 'A-tisket a-tasket A green and yellow basket;",
"assert.strictEqual(truncate('A-tisket a-tasket A green and yellow basket, 24), 'A-tisket…, should truncate string the given length');", "assert.strictEqual(truncate('A-tisket a-tasket A green and yellow basket, 24), 'A-tisket…, should truncate string the given length');",
"assert.strictEqual(truncate('A-tisket a-tasket A green and yellow basket, 'A-tisket a-tasket A green and yellow basket.length), string, 'should not truncate if string is = length');", "assert.strictEqual(truncate('A-tisket a-tasket A green and yellow basket, 'A-tisket a-tasket A green and yellow basket.length), string, 'should not truncate if string is = length');",
"assert.strictEqual(truncate('A-tisket a-tasket A green and yellow basket, 'A-tisket a-tasket A green and yellow basket.length + 2), string, 'should not truncate if string is < length');" "assert.strictEqual(truncate('A-tisket a-tasket A green and yellow basket, 'A-tisket a-tasket A green and yellow basket.length + 2), string, 'should not truncate if string is < length');"