Skip to content

Commit 3b852b1

Browse files
author
rsjpublic
committed
Fix more tests. All tests passing now in DE org.
1 parent 04c68b1 commit 3b852b1

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/classes/testEncoder.cls

+5-3
Original file line numberDiff line numberDiff line change
@@ -90,11 +90,11 @@ private class testEncoder {
9090

9191
jsInHtmlEncodeTests.add(new EncodeTest('abc', 'abc', 'Valid #1', true));
9292
jsInHtmlEncodeTests.add(new EncodeTest('abc<b>test</b>def', 'abc&lt;b&gt;test&lt;/b&gt;def', 'Valid #2', true));
93-
jsInHtmlEncodeTests.add(new EncodeTest('abc&lt;def', 'abc&amp;lt;def', 'Valid #3', true));
94-
jsInHtmlEncodeTests.add(new EncodeTest('abc<fghgfh&lt;<sfdg>&amp;def', 'abc&lt;fghgfh&amp;lt;&lt;sfdg&gt;&amp;amp;def', 'Valid #4', true));
93+
jsInHtmlEncodeTests.add(new EncodeTest('abc&lt;def', 'abc\\\\&amp;lt;def', 'Valid #3', true));
94+
jsInHtmlEncodeTests.add(new EncodeTest('abc<fghgfh&lt;<sfdg>&amp;def', 'abc&lt;fghgfh\\\\&amp;lt;&lt;sfdg&gt;\\\\&amp;amp;def', 'Valid #4', true));
9595
jsInHtmlEncodeTests.add(new EncodeTest('abc\'def', 'abc\\&#39;def', 'Valid #5', true));
9696
jsInHtmlEncodeTests.add(new EncodeTest('abc"def', 'abc\\&quot;def', 'Valid #6', true));
97-
jsInHtmlEncodeTests.add(new EncodeTest('abc&def', 'abc\\&amp;def', 'Valid #7', true));
97+
jsInHtmlEncodeTests.add(new EncodeTest('abc&def', 'abc\\\\&amp;def', 'Valid #7', true));
9898
jsInHtmlEncodeTests.add(new EncodeTest('abc\\def', 'abc\\\\def', 'Valid #8', true));
9999
jsInHtmlEncodeTests.add(new EncodeTest('abc\rdef', 'abc\\rdef', 'Valid #9', true));
100100
jsInHtmlEncodeTests.add(new EncodeTest('abc\ndef', 'abc\\ndef', 'Valid #10', true));
@@ -169,6 +169,8 @@ private class testEncoder {
169169
// if no exception - check if we are expecting a valid test
170170
System.assert(t.expectedResult == true, t.errText);
171171
// also make sure return value is equal to input
172+
System.debug('expected: ' + t.expectedOutput);
173+
System.debug('observed: ' + ret);
172174
System.assert(ret.equals(t.expectedOutput), t.errText);
173175
} catch (Exception e) {
174176
// if exception - check if we are expecting an invalid test

0 commit comments

Comments
 (0)