PLSQL/Lexer/test/unit/src/org/netbeans/modules/plsql/lexer/PlsqlBlockFactoryTest.java
1.1 --- a/PLSQL/Lexer/test/unit/src/org/netbeans/modules/plsql/lexer/PlsqlBlockFactoryTest.java Mon May 20 13:13:42 2013 +0530
1.2 +++ b/PLSQL/Lexer/test/unit/src/org/netbeans/modules/plsql/lexer/PlsqlBlockFactoryTest.java Mon Aug 12 11:26:54 2013 +0530
1.3 @@ -568,6 +568,28 @@
1.4 }
1.5 }
1.6
1.7 + @Test
1.8 + public void testForComments() throws IOException, BadLocationException {
1.9 + System.out.println("Test for Comment blocks ");
1.10 + final String plsqlFileName = "TestComments.apy";
1.11 + FileObject fileObject = fs.getRoot().createData(plsqlFileName);
1.12 + assertNotNull(fileObject);
1.13 + try {
1.14 + PlsqlBlockFactory blockFac = loadAsTmpFile(fileObject, plsqlFileName);
1.15 + assertNotNull(blockFac);
1.16 +
1.17 + List<PlsqlBlock> lstBlockFac = blockFac.getBlockHierarchy();
1.18 + //printHierarchy(lstBlockFac, "");
1.19 + //assertEquals(2, lstBlockFac.size());
1.20 + processBlocks(plsqlFileName, lstBlockFac);
1.21 +
1.22 + } finally {
1.23 + if (fileObject != null) {
1.24 + fileObject.delete();
1.25 + }
1.26 + }
1.27 + }
1.28 +
1.29
1.30 private PlsqlBlockFactory loadAsTmpFile(FileObject fileObj, String fileName) throws IOException, BadLocationException {
1.31 InputStream inputStream = new FileInputStream(new File(getDataDir(), fileName));