Run migrations in a transaction (#60)

This commit is contained in:
Michael Gaffney authored and GitHub committed 2020-05-16 13:26:57 -04:00
1 parent f8b456f3a7
commit 3d614dd732
3 files changed
+13 -1

No files matched your search

@@ -1,3 +1,5 @@
begin;
-- create test tables used in the unit tests for the internal/db package
-- these tables (db_test_user, db_test_car, db_test_rental) are not part
-- of the Watchtower domain model... they are simply used for testing the internal/db package
@@ -28,3 +30,5 @@ CREATE TABLE if not exists db_test_rental (
user_id bigint not null REFERENCES db_test_user(id),
car_id bigint not null REFERENCES db_test_car(id)
);
commit;