mirror of
https://github.com/dlang-community/DCD.git
synced 2025-04-26 13:19:56 +03:00
Tests for #228
This commit is contained in:
parent
0c4b75f0c7
commit
0822bddd49
5 changed files with 32 additions and 0 deletions
7
tests/imports/point.d
Normal file
7
tests/imports/point.d
Normal file
|
@ -0,0 +1,7 @@
|
|||
module point;
|
||||
|
||||
struct Point
|
||||
{
|
||||
int x;
|
||||
int y;
|
||||
}
|
1
tests/tc011/expected1.txt
Normal file
1
tests/tc011/expected1.txt
Normal file
|
@ -0,0 +1 @@
|
|||
Point s
|
2
tests/tc011/expected2.txt
Normal file
2
tests/tc011/expected2.txt
Normal file
|
@ -0,0 +1,2 @@
|
|||
x v
|
||||
y v
|
14
tests/tc011/file.d
Normal file
14
tests/tc011/file.d
Normal file
|
@ -0,0 +1,14 @@
|
|||
// Issue #228
|
||||
|
||||
import p = point;
|
||||
|
||||
unittest
|
||||
{
|
||||
p.
|
||||
}
|
||||
|
||||
unittest
|
||||
{
|
||||
p.Point p1;
|
||||
p1.
|
||||
}
|
8
tests/tc011/run.sh
Executable file
8
tests/tc011/run.sh
Executable file
|
@ -0,0 +1,8 @@
|
|||
set -e
|
||||
set -u
|
||||
|
||||
dcd-client file.d -c48 > actual1.txt
|
||||
diff actual1.txt expected1.txt
|
||||
|
||||
dcd-client file.d -c80 > actual2.txt
|
||||
diff actual2.txt expected2.txt
|
Loading…
Add table
Add a link
Reference in a new issue