File tree Expand file tree Collapse file tree 3 files changed +33
-6
lines changed
Expand file tree Collapse file tree 3 files changed +33
-6
lines changed Original file line number Diff line number Diff line change 1+ import os
12import subprocess
23
34
@@ -7,11 +8,19 @@ def test_comments() -> None:
78 stdout = subprocess .PIPE ,
89 check = False ,
910 )
10- assert result .stdout == b"Hello World!\n "
11+
12+ if os .name == "nt" :
13+ assert result .stdout == b"Hello World!\r \n "
14+ else :
15+ assert result .stdout == b"Hello World!\n "
1116
1217 result = subprocess .run (
1318 ["valthon" , "tests/comments.vln" ],
1419 stdout = subprocess .PIPE ,
1520 check = False ,
1621 )
17- assert result .stdout == b"Hello World!\n "
22+
23+ if os .name == "nt" :
24+ assert result .stdout == b"Hello World!\r \n "
25+ else :
26+ assert result .stdout == b"Hello World!\n "
Original file line number Diff line number Diff line change 1+ import os
12import subprocess
23
34
@@ -7,11 +8,19 @@ def test_function() -> None:
78 stdout = subprocess .PIPE ,
89 check = False ,
910 )
10- assert result .stdout == b"Hello World!\n "
11+
12+ if os .name == "nt" :
13+ assert result .stdout == b"Hello World!\r \n "
14+ else :
15+ assert result .stdout == b"Hello World!\n "
1116
1217 result = subprocess .run (
1318 ["valthon" , "tests/function.vln" ],
1419 stdout = subprocess .PIPE ,
1520 check = False ,
1621 )
17- assert result .stdout == b"Hello World!\n "
22+
23+ if os .name == "nt" :
24+ assert result .stdout == b"Hello World!\r \n "
25+ else :
26+ assert result .stdout == b"Hello World!\n "
Original file line number Diff line number Diff line change 1+ import os
12import subprocess
23
34
@@ -7,11 +8,19 @@ def test_function() -> None:
78 stdout = subprocess .PIPE ,
89 check = False ,
910 )
10- assert result .stdout == b"1\n "
11+
12+ if os .name == "nt" :
13+ assert result .stdout == b"1\r \n "
14+ else :
15+ assert result .stdout == b"1\n "
1116
1217 result = subprocess .run (
1318 ["valthon" , "tests/imports.vln" ],
1419 stdout = subprocess .PIPE ,
1520 check = False ,
1621 )
17- assert result .stdout == b"1\n "
22+
23+ if os .name == "nt" :
24+ assert result .stdout == b"1\r \n "
25+ else :
26+ assert result .stdout == b"1\n "
You can’t perform that action at this time.
0 commit comments