From 4c001b07277b8ee3159a0d22d27357ba3123f7ab Mon Sep 17 00:00:00 2001 From: Hackerpilot Date: Wed, 6 Jan 2016 01:08:55 -0800 Subject: [PATCH] Test case for #275 --- tests/tc023/expected1.txt | 9 +++++++++ tests/tc023/expected2.txt | 9 +++++++++ tests/tc023/file.d | 16 ++++++++++++++++ tests/tc023/run.sh | 8 ++++++++ 4 files changed, 42 insertions(+) create mode 100644 tests/tc023/expected1.txt create mode 100644 tests/tc023/expected2.txt create mode 100644 tests/tc023/file.d create mode 100755 tests/tc023/run.sh diff --git a/tests/tc023/expected1.txt b/tests/tc023/expected1.txt new file mode 100644 index 0000000..1f0d82d --- /dev/null +++ b/tests/tc023/expected1.txt @@ -0,0 +1,9 @@ +identifiers +alignof k +init k +mangleof k +sizeof k +stringof k +tupleof k +x v +y v diff --git a/tests/tc023/expected2.txt b/tests/tc023/expected2.txt new file mode 100644 index 0000000..1f0d82d --- /dev/null +++ b/tests/tc023/expected2.txt @@ -0,0 +1,9 @@ +identifiers +alignof k +init k +mangleof k +sizeof k +stringof k +tupleof k +x v +y v diff --git a/tests/tc023/file.d b/tests/tc023/file.d new file mode 100644 index 0000000..cbe4ba9 --- /dev/null +++ b/tests/tc023/file.d @@ -0,0 +1,16 @@ +module file; + +import point; +import point : P = Point; + +unittest +{ + P thePoint; + thePoint. +} + +unittest +{ + Point p; + p. +} diff --git a/tests/tc023/run.sh b/tests/tc023/run.sh new file mode 100755 index 0000000..86ea69f --- /dev/null +++ b/tests/tc023/run.sh @@ -0,0 +1,8 @@ +set -e +set -u + +../../bin/dcd-client file.d -c117 > actual1.txt +diff actual1.txt expected1.txt + +../../bin/dcd-client file.d -c89 > actual2.txt +diff actual2.txt expected2.txt