Skip to content

Commit b7ffcea

Browse files
committed
upgrade packages on demo test
1 parent f102635 commit b7ffcea

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

scripts/isolated-demo-test.ts

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,12 +74,22 @@ const processDemo = async (demoName: string): Promise<DemoResult> => {
7474
}
7575
};
7676

77+
// Run pnpm upgrade on local packages
78+
try {
79+
execSync('pnpm upgrade "@powersync/*"');
80+
} catch (ex) {
81+
console.error(ex);
82+
result.installResult.state = TestState.FAILED;
83+
result.installResult.error = ex.message;
84+
return result;
85+
}
86+
7787
// Run pnpm install and pnpm build
7888
try {
7989
execSync('pnpm install', { cwd: demoDest, stdio: 'inherit' });
8090
result.installResult.state = TestState.PASSED;
8191
} catch (ex) {
82-
console.error('Error installing packages: ', ex);
92+
console.error(ex);
8393
result.installResult.state = TestState.FAILED;
8494
result.installResult.error = ex.message;
8595
return result;
@@ -94,7 +104,7 @@ const processDemo = async (demoName: string): Promise<DemoResult> => {
94104
execSync('pnpm run clean', { cwd: demoDest, stdio: 'inherit' });
95105
result.installResult.state = TestState.PASSED;
96106
} catch (ex) {
97-
console.error('Error running "pnpm run clean": ', ex);
107+
console.error(ex);
98108
result.installResult.state = TestState.FAILED;
99109
result.installResult.error = ex.message;
100110
return result;
@@ -114,7 +124,7 @@ const processDemo = async (demoName: string): Promise<DemoResult> => {
114124
execSync('pnpm run test:build', { cwd: demoDest, stdio: 'inherit' });
115125
result.buildResult.state = TestState.PASSED;
116126
} catch (ex) {
117-
console.error('Error running "pnpm run "test:build": ', ex);
127+
console.error(ex);
118128
result.buildResult.state = TestState.FAILED;
119129
result.buildResult.error = ex.message;
120130
}

0 commit comments

Comments
 (0)