Skip to content

Commit

Permalink
prepare reusable test helper
Browse files Browse the repository at this point in the history
  • Loading branch information
mattpolzin committed Dec 10, 2024
1 parent 611da4d commit 20df1b9
Show file tree
Hide file tree
Showing 13 changed files with 14 additions and 12 deletions.
2 changes: 1 addition & 1 deletion tests/alias_query/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json AliasQuery.idr < input
../run.sh $1 AliasQuery.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/alias_statement/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json --check AliasStatement.idr
../run.sh $1 AliasStatement.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/expected_type_query/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json ExpectedTypeQuery.idr < input
../run.sh $1 ExpectedTypeQuery.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/inner_join_query/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json JoinQuery.idr < input
../run.sh $1 JoinQuery.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/inner_join_statement/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json --check JoinStatement.idr
../run.sh $1 JoinStatement.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/insert_query/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json InsertQuery.idr < input
../run.sh $1 InsertQuery.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/left_join_query/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json JoinQuery.idr < input
../run.sh $1 JoinQuery.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/left_join_statement/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json --check LeftJoinStatement.idr
../run.sh $1 LeftJoinStatement.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/print_alias_statement/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json AliasStatement.idr < input
../run.sh $1 AliasStatement.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/print_double_join_statement/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json DoubleJoinStatement.idr < input
../run.sh $1 DoubleJoinStatement.idr input

rm -rf build
2 changes: 1 addition & 1 deletion tests/print_left_and_inner_join_statements/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json LeftAndInnerJoinStatements.idr < input
../run.sh $1 LeftAndInnerJoinStatements.idr input

rm -rf build
2 changes: 2 additions & 0 deletions tests/run.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#!/usr/bin/env bash
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package elab-util --package parser --package parser-json $2 < $3
2 changes: 1 addition & 1 deletion tests/table_query/run
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
$1 --no-color --console-width 0 --no-banner --package pg-idris --package pg-idris-tests --package indexed --package parser-json TableQuery.idr < input
../run.sh $1 TableQuery.idr input

rm -rf build

0 comments on commit 20df1b9

Please sign in to comment.