diff --git a/bats/create-tables.bats b/bats/create-tables.bats index 4002daa9eb..f9a4f6b3fa 100755 --- a/bats/create-tables.bats +++ b/bats/create-tables.bats @@ -118,6 +118,12 @@ teardown() { [[ "$output" =~ "Error creating reader" ]] || false } +@test "try to create a table with dolt table import with a bad file name" { + run dolt table import -c test `batshelper bad.data` + skip "This panics right now with: panic: Unsupported table format should have failed before reaching here." + [ "$status" -eq 1 ] +} + @test "create a table with two primary keys from csv import" { run dolt table import -c --pk=pk1,pk2 test `batshelper 2pk5col-ints.csv` [ "$status" -eq 0 ] @@ -329,4 +335,4 @@ teardown() { [ $status -eq 0 ] [ "${lines[0]}" = "diff --dolt a/test b/test" ] [ "${lines[1]}" = "added table" ] -} \ No newline at end of file +} diff --git a/bats/helper/bad.data b/bats/helper/bad.data new file mode 100644 index 0000000000..2d8fc28397 --- /dev/null +++ b/bats/helper/bad.data @@ -0,0 +1,2 @@ +this,is,bad +real,bad,