|
@@ -0,0 +1,79 @@
|
|
1
|
+#!/bin/bash
|
|
2
|
+
|
|
3
|
+. "$TF_DIR/include/subtest.sh"
|
|
4
|
+. "$TF_DIR/include/tools.sh"
|
|
5
|
+
|
|
6
|
+. "$(shellfu-get path)" || tf_exit_error "failed to init shellfu"
|
|
7
|
+SHELLFU_PATH=$(satcmd --saturnin-get-shellfu-path)
|
|
8
|
+shellfu import saturnin || tf_exit_error "failed to import saturnin"
|
|
9
|
+
|
|
10
|
+tf_enum_subtests() {
|
|
11
|
+ echo "merge_first"
|
|
12
|
+ echo "merge_first_no1"
|
|
13
|
+ echo "merge_first_no2"
|
|
14
|
+ echo "merge_first_no3"
|
|
15
|
+ echo "merge_first_none"
|
|
16
|
+ echo "merge_first_only1"
|
|
17
|
+ echo "merge_first_only2"
|
|
18
|
+ echo "merge_first_only3"
|
|
19
|
+ echo "merge_first_raw"
|
|
20
|
+ echo "merge_join"
|
|
21
|
+ echo "merge_join_no1"
|
|
22
|
+ echo "merge_join_no2"
|
|
23
|
+ echo "merge_join_no3"
|
|
24
|
+ echo "merge_join_only1"
|
|
25
|
+ echo "merge_join_only2"
|
|
26
|
+ echo "merge_join_only3"
|
|
27
|
+ echo "merge_join_none"
|
|
28
|
+ echo "merge_join_raw"
|
|
29
|
+}
|
|
30
|
+
|
|
31
|
+tf_do_subtest() {
|
|
32
|
+ local name=$1
|
|
33
|
+ local o_out="oracle/$name.stdout"
|
|
34
|
+ local o_es=0
|
|
35
|
+ local cmd
|
|
36
|
+ local t_paths
|
|
37
|
+ local t_args
|
|
38
|
+ case $name in
|
|
39
|
+ merge_first)
|
|
40
|
+ t_paths='test/merge-a:test/merge-b'; t_args='s1.k1 t.conf' ;;
|
|
41
|
+ merge_first_no1)
|
|
42
|
+ t_paths='test/merge-x:test/merge-a:test/merge-b'; t_args='s1.k1 t.conf' ;;
|
|
43
|
+ merge_first_no2)
|
|
44
|
+ t_paths='test/merge-a:test/merge-x:test/merge-b'; t_args='s1.k1 t.conf' ;;
|
|
45
|
+ merge_first_no3)
|
|
46
|
+ t_paths='test/merge-a:test/merge-b:test/merge-x'; t_args='s1.k1 t.conf' ;;
|
|
47
|
+ merge_first_none)
|
|
48
|
+ t_paths='test/merge-x:test/merge-y:test/merge-z'; t_args='s1.k1 t.conf'; o_es=1 ;;
|
|
49
|
+ merge_first_only1)
|
|
50
|
+ t_paths='test/merge-b:test/merge-x:test/merge-y'; t_args='s1.k1 t.conf' ;;
|
|
51
|
+ merge_first_only2)
|
|
52
|
+ t_paths='test/merge-x:test/merge-b:test/merge-y'; t_args='s1.k1 t.conf' ;;
|
|
53
|
+ merge_first_only3)
|
|
54
|
+ t_paths='test/merge-x:test/merge-y:test/merge-b'; t_args='s1.k1 t.conf' ;;
|
|
55
|
+ merge_first_raw)
|
|
56
|
+ t_paths='test/merge-a:test/merge-b'; t_args='-r s2.k2 t.conf' ;;
|
|
57
|
+ merge_join)
|
|
58
|
+ t_paths='test/merge-a:test/merge-b'; t_args='-j s1.k1 t.conf' ;;
|
|
59
|
+ merge_join_no1)
|
|
60
|
+ t_paths='test/merge-x:test/merge-a:test/merge-b'; t_args='-j s1.k1 t.conf' ;;
|
|
61
|
+ merge_join_no2)
|
|
62
|
+ t_paths='test/merge-a:test/merge:x:test/merge-b'; t_args='-j s1.k1 t.conf' ;;
|
|
63
|
+ merge_join_no3)
|
|
64
|
+ t_paths='test/merge-a:test/merge-b:test/merge:x'; t_args='-j s1.k1 t.conf' ;;
|
|
65
|
+ merge_join_none)
|
|
66
|
+ t_paths='test/merge-x:test/merge-y:test/merge-z'; t_args='-j s1.k1 t.conf'; o_es=1 ;;
|
|
67
|
+ merge_join_only1)
|
|
68
|
+ t_paths='test/merge-b:test/merge-x:test/merge-y'; t_args='-j s1.k1 t.conf' ;;
|
|
69
|
+ merge_join_only2)
|
|
70
|
+ t_paths='test/merge-x:test/merge-b:test/merge-y'; t_args='-j s1.k1 t.conf' ;;
|
|
71
|
+ merge_join_only3)
|
|
72
|
+ t_paths='test/merge-x:test/merge-y:test/merge-b'; t_args='-j s1.k1 t.conf' ;;
|
|
73
|
+ merge_join_raw)
|
|
74
|
+ t_paths='test/merge-a:test/merge-b'; t_args='-j -r s2.k2 t.conf' ;;
|
|
75
|
+ esac
|
|
76
|
+ tf_testflt -n "$name" -O "$o_out" -S "$o_es" "SATURNIN_CONF_PATH=$t_paths saturnin__conf $t_args"
|
|
77
|
+}
|
|
78
|
+
|
|
79
|
+tf_do_subtests
|