Skip to content

Commit

Permalink
misc: do not publish lighthouse-cli/test except smokehouse (#12415)
Browse files Browse the repository at this point in the history
  • Loading branch information
connorjclark authored May 1, 2021
1 parent c333322 commit dee182a
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
7 changes: 5 additions & 2 deletions .npmignore
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,11 @@ lighthouse-logger/
!lighthouse-core/scripts/manual-chrome-launcher.js
!lighthouse-core/scripts/download-chrome.sh

# keep smokehouse tests, etc
!lighthouse-cli/test
# Exclude the CLI smoketests but keep the smoketest runner that is used
# by downstream projects (e.g. publisher ads).
lighthouse-cli/test/cli
lighthouse-cli/test/fixtures
lighthouse-cli/test/smokehouse/test-definitions

results/
lantern-data/
Expand Down
2 changes: 1 addition & 1 deletion lighthouse-cli/test/smokehouse/frontends/smokehouse-bin.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const log = require('lighthouse-logger');
const {runSmokehouse} = require('../smokehouse.js');
const {server, serverForOffline} = require('../../fixtures/static-server.js');

const coreTestDefnsPath = require.resolve('../test-definitions/core-tests.js');
const coreTestDefnsPath = `${__dirname}/../test-definitions/core-tests.js`;

/**
* Possible Lighthouse runners. Loaded dynamically so e.g. a CLI run isn't
Expand Down
6 changes: 4 additions & 2 deletions lighthouse-core/scripts/release/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,10 @@ cd /tmp/lighthouse-local-test

npm init -y
npm install "$LH_PRISTINE_ROOT/lighthouse-$VERSION.tgz"
cd node_modules/lighthouse/lighthouse-cli/test/ && npm install lodash.clonedeep && cd ../../../../
npm explore lighthouse -- npm run smoke -- --retries=3
npx add-dependencies package.json mime-types lodash.clonedeep
npm install --only=prod
cp -r "$LH_PRISTINE_ROOT/lighthouse-cli/test/fixtures" node_modules/lighthouse/lighthouse-cli/test
npm explore lighthouse -- npm run smoke -- --tests-path "$LH_PRISTINE_ROOT/lighthouse-cli/test/smokehouse/test-definitions/core-tests.js" --retries=3
npm explore lighthouse -- npm run fast -- http://example.com

cd "$LH_PRISTINE_ROOT"
Expand Down

0 comments on commit dee182a

Please sign in to comment.