test(processor): single-line block + inline/block flag cases
This commit is contained in:
+1
@@ -0,0 +1 @@
|
|||||||
|
int a = 1; /* one */ int b = 2; /* two */ int c = 3;
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
int a = 1; int b = 2; int c = 3;
|
||||||
+1
@@ -0,0 +1 @@
|
|||||||
|
var x = 5; /* c */ var y = 10;
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
var x = 5; var y = 10;
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
code(); /* block */ // line
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
code(); // line
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
code(); /* block */ // line
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
code(); /* block */
|
||||||
@@ -97,6 +97,10 @@ func TestWholeFile(t *testing.T) {
|
|||||||
{name: "intentional blank lines preserved", file: "py_blanks.py"},
|
{name: "intentional blank lines preserved", file: "py_blanks.py"},
|
||||||
{name: "escaped quote then line comment", file: "js_escaped.js"},
|
{name: "escaped quote then line comment", file: "js_escaped.js"},
|
||||||
{name: "lua marker in string vs real comment", file: "lua_string.lua"},
|
{name: "lua marker in string vs real comment", file: "lua_string.lua"},
|
||||||
|
{name: "single-line block comment removed", file: "js_block.js"},
|
||||||
|
{name: "multiple single-line blocks on one line", file: "c_multiblock.c"},
|
||||||
|
{name: "--inline removes only line comments", file: "js_inline_flag.js", cli: types.CLI{Inline: true}},
|
||||||
|
{name: "--block removes only block comments", file: "js_block_flag.js", cli: types.CLI{Block: true}},
|
||||||
}
|
}
|
||||||
|
|
||||||
for _, tc := range cases {
|
for _, tc := range cases {
|
||||||
|
|||||||
Reference in New Issue
Block a user