From 6c3c67fa2f4fab8fb7e8618f15d53ed79dee0642 Mon Sep 17 00:00:00 2001
From: davu <davu@mir-robots.com>
Date: Sun, 12 Mar 2023 19:17:52 +0100
Subject: [PATCH] updating dcd tests

---
 tests/tc_calltip_in_func/file.d               | 14 ++++++++++++++
 tests/tc_calltip_in_func/run.sh               |  2 +-
 tests/tc_erroneous_body_content/expected1.txt |  1 +
 tests/tc_incomplete_switch/expected1.txt      |  1 +
 tests/tc_ufcs_calltip_in_func/file.d          |  2 ++
 tests/tc_ufcs_calltip_in_func/run.sh          |  2 +-
 6 files changed, 20 insertions(+), 2 deletions(-)
 create mode 100644 tests/tc_calltip_in_func/file.d

diff --git a/tests/tc_calltip_in_func/file.d b/tests/tc_calltip_in_func/file.d
new file mode 100644
index 0000000..4b62f81
--- /dev/null
+++ b/tests/tc_calltip_in_func/file.d
@@ -0,0 +1,14 @@
+class Bar
+{
+	void fun(A param)
+	{
+	}
+}
+
+class Foo
+{
+	void foo(Bar bar)
+	{
+		bar.fun(
+	}
+}
diff --git a/tests/tc_calltip_in_func/run.sh b/tests/tc_calltip_in_func/run.sh
index b72bb14..ba2553c 100755
--- a/tests/tc_calltip_in_func/run.sh
+++ b/tests/tc_calltip_in_func/run.sh
@@ -1,5 +1,5 @@
 set -e
 set -u
 
-../../bin/dcd-client $1 -c66 <<< "class Bar{void fun(A param){}}class Foo{void foo(Bar bar){bar.fun(}}" > actual.txt
+../../bin/dcd-client $1 file.d -c84 > actual.txt
 diff actual.txt expected.txt --strip-trailing-cr
diff --git a/tests/tc_erroneous_body_content/expected1.txt b/tests/tc_erroneous_body_content/expected1.txt
index 12a38bb..6dd7ccf 100644
--- a/tests/tc_erroneous_body_content/expected1.txt
+++ b/tests/tc_erroneous_body_content/expected1.txt
@@ -1,6 +1,7 @@
 identifiers
 alignof	k
 b	v
+bar	F
 init	k
 mangleof	k
 sizeof	k
diff --git a/tests/tc_incomplete_switch/expected1.txt b/tests/tc_incomplete_switch/expected1.txt
index 5d30ee5..de86c55 100644
--- a/tests/tc_incomplete_switch/expected1.txt
+++ b/tests/tc_incomplete_switch/expected1.txt
@@ -2,6 +2,7 @@ identifiers
 __monitor	v
 __vptr	v
 alignof	k
+bar	F
 classinfo	v
 e	v
 init	k
diff --git a/tests/tc_ufcs_calltip_in_func/file.d b/tests/tc_ufcs_calltip_in_func/file.d
index 5299951..8de68ba 100644
--- a/tests/tc_ufcs_calltip_in_func/file.d
+++ b/tests/tc_ufcs_calltip_in_func/file.d
@@ -2,6 +2,8 @@ void showSomething(int x, string message, bool ok){}
 void showSomething(int x, string message, bool ok, float percentage){}
 void showSomething(string x, string message, bool ok){}
 void showSomething(){}
+void showSomething(){}
+void showNothing(int x){}
 int showSomething;
 struct showSomething { int x; }
 
diff --git a/tests/tc_ufcs_calltip_in_func/run.sh b/tests/tc_ufcs_calltip_in_func/run.sh
index a885d86..f3b8368 100755
--- a/tests/tc_ufcs_calltip_in_func/run.sh
+++ b/tests/tc_ufcs_calltip_in_func/run.sh
@@ -1,5 +1,5 @@
 set -e
 set -u
 
-../../bin/dcd-client $1 -c293 file.d > actual.txt
+../../bin/dcd-client $1 -c342 file.d > actual.txt
 diff actual.txt expected.txt --strip-trailing-cr