Skip to content

Commit

Permalink
test setup SQL
Browse files Browse the repository at this point in the history
  • Loading branch information
SingingBush committed Nov 2, 2024
1 parent 84de0c2 commit 6f3947d
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions test/ddbctest/mysqltest.d
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ version(USE_MYSQL) {
this() {
super(
"ddbc:mysql://localhost:%s/testdb?user=testuser,password=passw0rd".format(environment.get("MYSQL_PORT", "3306")),
"CREATE TABLE records (id SERIAL PRIMARY KEY, name VARCHAR(255) NOT NULL)",
"DROP TABLE IF EXISTS records"
"CREATE TABLE my_first_test (id SERIAL PRIMARY KEY, name VARCHAR(255) NOT NULL);CREATE TABLE records (id SERIAL PRIMARY KEY, name VARCHAR(255) NOT NULL)",
"DROP TABLE IF EXISTS my_first_test;DROP TABLE IF EXISTS records"
);
}

Expand Down
4 changes: 2 additions & 2 deletions test/ddbctest/odbctest.d
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ version(USE_ODBC) {
this() {
super(
"odbc://localhost,%s?user=SA,password=MSbbk4k77JKH88g54,trusted_connection=yes,driver=ODBC Driver 18 for SQL Server".format(environment.get("MSSQL_PORT", "1433")), // don't specify database!
"CREATE TABLE records (id INT IDENTITY(1, 1) PRIMARY KEY, name VARCHAR(255) NOT NULL)",
"DROP TABLE IF EXISTS records"
"DROP TABLE IF EXISTS [my_first_test];CREATE TABLE [my_first_test] ([id] INT NOT NULL IDENTITY(1,1) PRIMARY KEY, [name] VARCHAR(255) NOT NULL);CREATE TABLE records (id INT IDENTITY(1, 1) PRIMARY KEY, name VARCHAR(255) NOT NULL)",
"DROP TABLE IF EXISTS [my_first_test];DROP TABLE IF EXISTS records"
);
}

Expand Down
4 changes: 2 additions & 2 deletions test/ddbctest/postgresqltest.d
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ version(USE_PGSQL) {
this() {
super(
"ddbc:postgresql://localhost:%s/testdb?user=testuser,password=passw0rd,ssl=false".format(environment.get("POSTGRES_PORT", "5432")),
"CREATE TABLE records (id SERIAL PRIMARY KEY, name VARCHAR(255) NOT NULL)",
"DROP TABLE IF EXISTS records"
"CREATE TABLE my_first_test (id SERIAL PRIMARY KEY, name VARCHAR(255) NOT NULL);CREATE TABLE records (id SERIAL PRIMARY KEY, name VARCHAR(255) NOT NULL)",
"DROP TABLE IF EXISTS my_first_test;DROP TABLE IF EXISTS records"
);
}

Expand Down

0 comments on commit 6f3947d

Please sign in to comment.