mirror of
https://github.com/dolthub/dolt.git
synced 2026-01-30 10:45:18 -06:00
Merge pull request #1316 from dolthub/db/fix-bats
[no-release-notes] /{.github,bats}: pin runner, add timeouts
This commit is contained in:
2
.github/workflows/ci-bats-tests.yaml
vendored
2
.github/workflows/ci-bats-tests.yaml
vendored
@@ -14,7 +14,7 @@ jobs:
|
||||
strategy:
|
||||
fail-fast: true
|
||||
matrix:
|
||||
os: [ ubuntu-18.04, macos-latest, windows-2019 ]
|
||||
os: [ ubuntu-18.04, macos-10.15, windows-2019 ]
|
||||
env:
|
||||
use_credentials: ${{ secrets.AWS_SECRET_ACCESS_KEY != '' && secrets.AWS_ACCESS_KEY_ID != '' }}
|
||||
steps:
|
||||
|
||||
2
.github/workflows/ci-go-tests.yaml
vendored
2
.github/workflows/ci-go-tests.yaml
vendored
@@ -13,7 +13,7 @@ jobs:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os: [macos-latest, ubuntu-18.04, windows-latest]
|
||||
os: [macos-10.15, ubuntu-18.04, windows-latest]
|
||||
steps:
|
||||
- name: Set up Go 1.x
|
||||
uses: actions/setup-go@v2
|
||||
|
||||
@@ -1,38 +1,60 @@
|
||||
#!/usr/bin/expect
|
||||
|
||||
set timeout 1
|
||||
set timeout 2
|
||||
spawn dolt sql
|
||||
expect {
|
||||
"doltsql> " { send "CREATE TABLE test(pk BIGINT PRIMARY KEY, v1 BIGINT);\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
"doltsql> " { send "INSERT INTO test VALUES (0,0);\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
"doltsql> " { send "DELIMITER $$ ;\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
"doltsql> " { send "INSERT INTO test VALUES (1,1)$$\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
"doltsql> " { send "delimiter # $$\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
"doltsql> " { send "CREATE TRIGGER tt BEFORE INSERT ON test FOR EACH ROW\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
" -> " { send "BEGIN\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
" -> " { send "SET NEW.v1 = NEW.v1 * 11;\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
" -> " { send "SET NEW.v1 = NEW.v1 * -10;\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
" -> " { send "END; #\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect {
|
||||
"doltsql> " { send "DeLiMiTeR ; #\r"; }
|
||||
timeout { exit 1; }
|
||||
failed { exit 1; }
|
||||
}
|
||||
expect eof
|
||||
|
||||
@@ -713,8 +713,8 @@ SQL
|
||||
cd doltsql
|
||||
dolt init
|
||||
|
||||
$BATS_TEST_DIRNAME/sql-delimiter.expect
|
||||
echo "$output"
|
||||
run $BATS_TEST_DIRNAME/sql-delimiter.expect
|
||||
[ "$status" -eq "0" ]
|
||||
[[ ! "$output" =~ "Error" ]] || false
|
||||
[[ ! "$output" =~ "error" ]] || false
|
||||
|
||||
|
||||
Reference in New Issue
Block a user