Пример #1
0
 @Test
 public void testFromReader() throws Exception {
   // Same as stubjslint.js.
   String jslint = "function JSLINT() {JSLINT.errors=[];return true}";
   StringReader reader = new StringReader(jslint);
   assertJSLintOK(builder.fromReader(reader, "stubjslint.js"));
 }
Пример #2
0
 @Test
 public void testFromDefault() throws Exception {
   assertJSLintOK(builder.fromDefault());
 }
Пример #3
0
 @Test
 public void testFromFile() throws Exception {
   File f = new File(getClass().getClassLoader().getResource(STUB_JSLINT).toURI());
   assertJSLintOK(builder.fromFile(f));
 }
Пример #4
0
 @Test
 public void testFromClasspathResource() throws Exception {
   assertJSLintOK(builder.fromClasspathResource(STUB_JSLINT));
 }