Skip to content

Commit

Permalink
chore: add vite ecosystem-ci command
Browse files Browse the repository at this point in the history
  • Loading branch information
sheremet-va committed Apr 30, 2024
1 parent a52964b commit cc8f058
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
"test": "pnpm --filter test-core test:threads",
"test:ci": "CI=true pnpm -r --reporter-hide-prefix --stream --filter '@vitest/test-*' --filter !test-browser run test",
"test:examples": "CI=true pnpm -r --reporter-hide-prefix --stream --filter '@vitest/example-*' run test",
"test:ecosystem-ci": "ECOSYSTEM_CI=true pnpm test:ci",
"typecheck": "tsc -p tsconfig.check.json --noEmit",
"typecheck:why": "tsc -p tsconfig.check.json --noEmit --explainFiles > explainTypes.txt",
"ui:build": "vite build packages/ui",
Expand Down
3 changes: 2 additions & 1 deletion test/cli/test/git-changed.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ const fileName = 'fixtures/git-changed/related/rerun.temp'
// NOTE: if there are any changes in fixtures/git-changed,
// most tests will probably fail

describe('forceRerunTrigger', () => {
// ecosystem-ci updated package.json and make this test fail
describe.skipIf(process.env.ECOSYSTEM_CI)('forceRerunTrigger', () => {
async function run() {
return runVitest({
root: join(process.cwd(), 'fixtures/git-changed/related'),
Expand Down
2 changes: 1 addition & 1 deletion test/cli/test/setup-files.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ describe('setup files with forceRerunTrigger', () => {
}

// Note that this test will fail locally if you have uncommitted changes
it.runIf(process.env.GITHUB_ACTIONS)('should run no tests if setup file is not changed', async () => {
it.runIf(process.env.GITHUB_ACTIONS && !process.env.ECOSYSTEM_CI)('should run no tests if setup file is not changed', async () => {
const { stdout } = await run()
expect(stdout).toContain('No test files found, exiting with code 0')
})
Expand Down

0 comments on commit cc8f058

Please sign in to comment.