We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1254649 commit d328d71Copy full SHA for d328d71
internal-packages/testcontainers/src/utils.ts
@@ -9,6 +9,14 @@ export async function createPostgresContainer() {
9
// Run migrations
10
const databasePath = path.resolve(__dirname, "../../database");
11
12
+ execSync(`npx prisma generate --schema ${databasePath}/prisma/schema.prisma`, {
13
+ env: {
14
+ ...process.env,
15
+ DATABASE_URL: container.getConnectionUri(),
16
+ DIRECT_URL: container.getConnectionUri(),
17
+ },
18
+ });
19
+
20
execSync(`npx prisma db push --schema ${databasePath}/prisma/schema.prisma`, {
21
env: {
22
...process.env,
0 commit comments