File tree Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Expand file tree Collapse file tree 1 file changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -207,6 +207,25 @@ SQLite.@register db big
207
207
r = query (db, " SELECT big(5)" )
208
208
@test r[1 ][1 ] == big (5 )
209
209
210
+
211
+ db2 = SQLiteDB ()
212
+ query (db2, " CREATE TABLE tab1 (r REAL, s INT)" )
213
+
214
+ @test_throws ErrorException create (db2, " tab1" , [2.1 3 ; 3.4 8 ])
215
+ # should not throw any exceptions
216
+ create (db2, " tab1" , [2.1 3 ; 3.4 8 ], ifnotexists= true )
217
+ create (db2, " tab2" , [2.1 3 ; 3.4 8 ])
218
+
219
+ @test_throws ErrorException drop (db2, " nonexistant" )
220
+ # should not throw anything
221
+ drop (db2, " nonexistant" , ifexists= true )
222
+ # should drop "tab2"
223
+ drop (db2, " tab2" , ifexists= true )
224
+ @test ! in (" tab2" , tables (db2)[1 ])
225
+
226
+ close (db2)
227
+
228
+
210
229
@test size (tables (db)) == (11 ,1 )
211
230
212
231
close (db)
You can’t perform that action at this time.
0 commit comments