From 1d5f0ee2e2d9baa28e4cbc3b6fb16677cd3afaa9 Mon Sep 17 00:00:00 2001 From: maxxcrawford Date: Mon, 12 Jun 2023 22:10:54 -0500 Subject: [PATCH 1/3] Add Circle CI config --- .circleci/config.yml | 19 +++++++++++++++++++ .travis.yml | 12 ------------ package.json | 3 +++ 3 files changed, 22 insertions(+), 12 deletions(-) create mode 100644 .circleci/config.yml delete mode 100644 .travis.yml diff --git a/.circleci/config.yml b/.circleci/config.yml new file mode 100644 index 000000000..3703464f5 --- /dev/null +++ b/.circleci/config.yml @@ -0,0 +1,19 @@ +# This config is equivalent to both the '.circleci/extended/orb-free.yml' and the base '.circleci/config.yml' +version: 2.1 + +# Orbs are reusable packages of CircleCI configuration that you may share across projects, enabling you to create encapsulated, parameterized commands, jobs, and executors that can be used across multiple projects. +# See: https://circleci.com/docs/orb-intro/ +orbs: + node: circleci/node@4.7 + +# Invoke jobs via workflows +# See: https://circleci.com/docs/configuration-reference/#workflows +workflows: + lint: + jobs: + - node/run: + npm-run: lint + test-ci: + jobs: + - node/run: + npm-run: test-ci \ No newline at end of file diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index e653656c6..000000000 --- a/.travis.yml +++ /dev/null @@ -1,12 +0,0 @@ -dist: xenial -services: - - xvfb -addons: - firefox: latest -language: node_js -node_js: - - "lts/*" -cache: npm -notifications: - irc: - - "ircs://irc.mozilla.org:6697/#testpilot-containers-bots" diff --git a/package.json b/package.json index cfc9e0ff9..63e1d8db7 100644 --- a/package.json +++ b/package.json @@ -4,12 +4,15 @@ "description": "Facebook Container isolates your Facebook activity from the rest of your web activity in order to prevent Facebook from tracking you outside of the Facebook website via third party cookies. ", "main": "background.js", "scripts": { + "test-ci": "mocha -test/functional/setup.js test/functional/*.test.js --timeout 60000", "test": "eslint src test && npm run coverage && npm run test-functional", "test-watch": "mocha --reporter=progress test/setup.js test/features/*.test.js --watch", "test-functional": "mocha --reporter=progress test/functional/setup.js test/functional/*.test.js --timeout 60000", "test-functional-dev": "cross-env NODE_ENV=development npm run test-functional", "coverage": "c8 --reporter=html --reporter=text mocha --reporter=progress test/setup.js test/features/*.test.js --timeout 60000", + "coverage:simple": "c8 mocha test/setup.js test/features/*.test.js --timeout 60000", "build": "npm test && web-ext build --overwrite-dest -s src", + "lint": "eslint src test", "dev": "web-ext run -s src --devtools" }, "repository": { From 66bf301a8dab7503f5e4382cac7295be87c0ab71 Mon Sep 17 00:00:00 2001 From: maxxcrawford Date: Thu, 6 Jul 2023 14:19:45 -0500 Subject: [PATCH 2/3] Use test command --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 3703464f5..5436ba9b9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -13,7 +13,7 @@ workflows: jobs: - node/run: npm-run: lint - test-ci: + test: jobs: - node/run: - npm-run: test-ci \ No newline at end of file + npm-run: test \ No newline at end of file From fb6eca2fa56f2f6ff792add03a751acabb1a811c Mon Sep 17 00:00:00 2001 From: maxxcrawford Date: Thu, 6 Jul 2023 14:23:42 -0500 Subject: [PATCH 3/3] Run feature tests --- .circleci/config.yml | 4 ++-- package.json | 3 +-- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 5436ba9b9..3703464f5 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -13,7 +13,7 @@ workflows: jobs: - node/run: npm-run: lint - test: + test-ci: jobs: - node/run: - npm-run: test \ No newline at end of file + npm-run: test-ci \ No newline at end of file diff --git a/package.json b/package.json index 63e1d8db7..406155149 100644 --- a/package.json +++ b/package.json @@ -4,13 +4,12 @@ "description": "Facebook Container isolates your Facebook activity from the rest of your web activity in order to prevent Facebook from tracking you outside of the Facebook website via third party cookies. ", "main": "background.js", "scripts": { - "test-ci": "mocha -test/functional/setup.js test/functional/*.test.js --timeout 60000", + "test-ci": "mocha test/setup.js test/features/*.test.js --timeout 60000", "test": "eslint src test && npm run coverage && npm run test-functional", "test-watch": "mocha --reporter=progress test/setup.js test/features/*.test.js --watch", "test-functional": "mocha --reporter=progress test/functional/setup.js test/functional/*.test.js --timeout 60000", "test-functional-dev": "cross-env NODE_ENV=development npm run test-functional", "coverage": "c8 --reporter=html --reporter=text mocha --reporter=progress test/setup.js test/features/*.test.js --timeout 60000", - "coverage:simple": "c8 mocha test/setup.js test/features/*.test.js --timeout 60000", "build": "npm test && web-ext build --overwrite-dest -s src", "lint": "eslint src test", "dev": "web-ext run -s src --devtools"