summaryrefslogtreecommitdiff
path: root/tests/core
diff options
context:
space:
mode:
authorVasilis Kalintiris <ehostunreach@gmail.com>2013-12-07 12:22:07 +0200
committerVasilis Kalintiris <ehostunreach@gmail.com>2013-12-07 19:35:55 +0200
commite4d05a96412b44b978d3b4f8a126b659738d56bf (patch)
treea7fc2d75302c474057eb2f027cc024159294320d /tests/core
parent155d737f1fa091ca34404f73d7fc315af4439e09 (diff)
Use do_run_from_file() for test_conststructs
Diffstat (limited to 'tests/core')
-rw-r--r--tests/core/test_conststructs.in21
-rw-r--r--tests/core/test_conststructs.out1
2 files changed, 22 insertions, 0 deletions
diff --git a/tests/core/test_conststructs.in b/tests/core/test_conststructs.in
new file mode 100644
index 00000000..e95fd6be
--- /dev/null
+++ b/tests/core/test_conststructs.in
@@ -0,0 +1,21 @@
+
+ #include <stdio.h>
+ struct IUB {
+ int c;
+ double p;
+ unsigned int pi;
+ };
+
+ int main( int argc, const char *argv[] ) {
+ int before = 70;
+ IUB iub[] = {
+ { 'a', 0.3029549426680, 5 },
+ { 'c', 0.15, 4 },
+ { 'g', 0.12, 3 },
+ { 't', 0.27, 2 },
+ };
+ int after = 90;
+ printf("*%d,%d,%d,%d,%d,%d*\n", before, iub[0].c, int(iub[1].p*100), iub[2].pi, int(iub[0].p*10000), after);
+ return 0;
+ }
+ \ No newline at end of file
diff --git a/tests/core/test_conststructs.out b/tests/core/test_conststructs.out
new file mode 100644
index 00000000..af600061
--- /dev/null
+++ b/tests/core/test_conststructs.out
@@ -0,0 +1 @@
+*70,97,15,3,3029,90* \ No newline at end of file