Skip to content

Commit e8713b2

Browse files
committed
1 parent eaab772 commit e8713b2

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed
Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
#!/usr/bin/env bats
2+
bats_require_minimum_version 1.5.0
23

34
load helper
45

56
setup_file() {
67
mysql_exec_stdin <<-'EOF'
78
CREATE DATABASE table_statement_test;
89
USE table_statement_test;
9-
CREATE TABLE peildatum (id INT, name VARCHAR(255));
10-
INSERT INTO peildatum VALUES (1, 'test1'), (2, 'test2');
10+
CREATE TABLE t (id INT, name VARCHAR(255));
11+
INSERT INTO t VALUES (1, 'test1'), (2, 'test2');
1112
EOF
1213
}
1314

@@ -18,8 +19,10 @@ EOF
1819
}
1920

2021
@test "TABLE statement should return all rows from the table" {
21-
run mysql_exec "TABLE table_statement_test.peildatum"
22-
[ "$status" -eq 0 ]
22+
run -0 mysql_exec_stdin <<-'EOF'
23+
USE table_statement_test;
24+
TABLE t;
25+
EOF
2326
[ "${lines[0]}" = "1 test1" ]
2427
[ "${lines[1]}" = "2 test2" ]
2528
}

0 commit comments

Comments
 (0)