-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ZATS-70: fix JS line comments causing Parse Errors
- Loading branch information
Showing
6 changed files
with
80 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
41 changes: 41 additions & 0 deletions
41
zats-mimic/src/test/java/org/zkoss/zats/testcase/ScriptTest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
package org.zkoss.zats.testcase; | ||
|
||
import org.junit.After; | ||
import org.junit.AfterClass; | ||
import org.junit.BeforeClass; | ||
import org.junit.Test; | ||
import org.zkoss.zats.mimic.ComponentAgent; | ||
import org.zkoss.zats.mimic.DesktopAgent; | ||
import org.zkoss.zats.mimic.Zats; | ||
import org.zkoss.zul.Listcell; | ||
|
||
import java.util.List; | ||
|
||
import static org.junit.Assert.assertEquals; | ||
import static org.junit.Assert.assertTrue; | ||
|
||
public class ScriptTest { | ||
|
||
@BeforeClass | ||
public static void init() { | ||
Zats.init("."); | ||
} | ||
|
||
@AfterClass | ||
public static void end() { | ||
Zats.end(); | ||
} | ||
|
||
@After | ||
public void after() { | ||
Zats.cleanup(); | ||
} | ||
|
||
@Test | ||
public void testSyntaxError() { | ||
DesktopAgent desktopAgent = Zats.newClient().connect("/~./basic/script.zul"); | ||
assertTrue(true); | ||
} | ||
|
||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<zk xmlns="http://www.zkoss.org/2005/zul"> | ||
|
||
<script type="text/javascript"> | ||
setTimeout('a()', 400); | ||
setTimeout('b()', 400); | ||
|
||
function getJSElement(zkId) { | ||
|
||
// This is a comment | ||
|
||
var jqId = '$' + zkId; | ||
var zkEl = zk.Widget.$(jq(jqId)); | ||
|
||
return document.getElementById(zkEl.uuid); | ||
} | ||
</script> | ||
|
||
<div height="100%"> | ||
|
||
</div> | ||
</zk> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters