Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(test): create integration test framework #32

Merged
merged 56 commits into from
Apr 19, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
d44e287
test: beginning integrations test writing
brodrigu Apr 13, 2021
cdf9385
feat: initial checks for function parameters
Apr 14, 2021
3ad467b
fix: validate util passing incorrect arg
Apr 14, 2021
db82333
test: building out a simple integration test structure
brodrigu Apr 14, 2021
485839d
fix: cleaning up files and stabilizing test platform
brodrigu Apr 14, 2021
88a9c34
ci: adding integration test workflow
brodrigu Apr 14, 2021
31f535e
Merge branch 'interest-groups' of github.com:MagniteEngineering/fledg…
brodrigu Apr 14, 2021
1c0904d
fix: removing unused test
brodrigu Apr 14, 2021
7353fa6
fix: remove unnecessary function
brodrigu Apr 14, 2021
743d292
chore: add utils unit tests
Apr 14, 2021
1020be6
fix: avoid calculating ms per day as per feedback
Apr 14, 2021
660cb21
chore: clean up error message for clarity as per feedback
Apr 14, 2021
f0ae5ef
chore: clean up test language
Apr 14, 2021
dfb53cf
chore: remove stub function
Apr 14, 2021
6bc1447
test: building out a real simple test
brodrigu Apr 14, 2021
ee2832d
chore: moving files to more appropriate locations
brodrigu Apr 14, 2021
3ea11c7
chore: remove all constants calculations
Apr 14, 2021
6093879
fix: import using relative path with file suffix
Apr 14, 2021
d45e691
chore: add in jsdocs
Apr 14, 2021
b0801cf
chore: remove unnecessary constants abstraction file
Apr 14, 2021
df7d65c
chore: move tests out of source directory
Apr 14, 2021
4bd8be2
chore: ignore mocks file from tests
Apr 14, 2021
ffa87ea
Merge branch 'join-interest-group' of github.com:MagniteEngineering/f…
brodrigu Apr 14, 2021
e98e2b3
fix: run integration and unit tests separately
brodrigu Apr 14, 2021
1f2082c
chore: move unit tests to subdirectory
Apr 14, 2021
ed09ed2
chore: create API docs
Apr 14, 2021
39df0e2
Merge branch 'join-interest-group' of github.com:MagniteEngineering/f…
brodrigu Apr 14, 2021
18da08f
chore: remove nvm dependency
brodrigu Apr 14, 2021
4253f4a
chore: using test:[test type]
brodrigu Apr 14, 2021
bb9f42a
chore: fixing some PR comments
brodrigu Apr 14, 2021
edfaa94
Merge branch 'interest-groups' into ig-happy-path-tests
Apr 15, 2021
b4edd03
chore: rename to server.js
Apr 15, 2021
ebffe06
chore: reuse npm task
Apr 15, 2021
02fd0af
chore: using cleaner method for puppeteer server
brodrigu Apr 15, 2021
1010277
fix: moving env out of ci
brodrigu Apr 15, 2021
6f86fa2
fix: using npm run serve instead of more direct node command
brodrigu Apr 15, 2021
a9061f8
Merge branch 'interest-groups' into ig-happy-path-tests
Apr 18, 2021
7b3e710
fix: merge in new output files
Apr 18, 2021
c10b558
chore: fix integration tests actions
Apr 18, 2021
8648913
fix: remove destructure
Apr 18, 2021
e4173e9
chore: ditch window?
Apr 18, 2021
77c076d
chore: console some errors on CI
Apr 18, 2021
4efeb46
chore: fix tests by fixing node version
Apr 18, 2021
84ed3df
chore: refactor actions (#34)
brodrigu Apr 18, 2021
09e2682
chore: remove unused dep
Apr 18, 2021
8b2afe1
fix: serve rewrites files, fix by renaming index to test
Apr 18, 2021
9dfcdb5
chore: set up dist task before integration tests
Apr 18, 2021
698d2bc
chore: set to nested window object
Apr 18, 2021
895e6bb
chore: fix URLs and include idb
Apr 18, 2021
2bc2340
chore: update babel, rollup configs
Apr 19, 2021
799d9c4
chore: update package lock
Apr 19, 2021
8274907
chore: follow protocols for e2e naming conventions
Apr 19, 2021
7444802
chore: fix GH actions
Apr 19, 2021
73163ee
chore: remove rollup config
Apr 19, 2021
ba8367c
chore: remove unused jest configs
Apr 19, 2021
048ff44
chore: clean up configs for tests
Apr 19, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
37 changes: 37 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: Lint

on:
push:
branches:
- '**'
- '!main'
pull_request:
branches:
- '**'
- '!main'

jobs:
prepare:
runs-on: ubuntu-latest
if: "! contains(github.event.head_commit.message, '[skip ci]')"
steps:
- run: echo "${{ github.event.head_commit.message }}"

lint:
needs: prepare
name: Lint
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v2
- name: setup node
uses: actions/setup-node@v2
with:
node-version: '14'
check-latest: true
- name: Install dependencies
env:
CI: true
run: npm ci
- name: Lint
run: npm run lint
15 changes: 8 additions & 7 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,19 @@ jobs:
strategy:
matrix:
node:
- 12
- 13
os:
- ubuntu-latest
- windows-latest
- macOS-latest
steps:
- name: checkout
uses: actions/checkout@v1
uses: actions/checkout@v2
- name: setup node
uses: actions/setup-node@v1
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}
node-version: '14'
check-latest: true
- name: Install dependencies
env:
CI: true
Expand All @@ -47,11 +47,12 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v1
uses: actions/checkout@v2
- name: setup node
uses: actions/setup-node@v1
uses: actions/setup-node@v2
with:
node-version: 13
node-version: '14'
check-latest: true
registry-url: https://registry.npmjs.org
- name: Install
env:
Expand Down
37 changes: 26 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,30 +17,45 @@ jobs:
steps:
- run: echo "${{ github.event.head_commit.message }}"

test:
unit:
needs: prepare
name: Test on node ${{ matrix.node }} and ${{ matrix.os }}
name: Unit test on node ${{ matrix.node }} and ${{ matrix.os }}
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v2
- name: setup node
uses: actions/setup-node@v2
with:
node-version: '14'
check-latest: true
- name: Install dependencies
env:
CI: true
run: npm ci
- name: Unit Test
run: npm run test:unit

e2e:
needs: prepare
name: End-to-End test on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
node:
- 13
- 14
os:
- ubuntu-latest
- windows-latest
- macOS-latest
steps:
- name: checkout
uses: actions/checkout@v1
uses: actions/checkout@v2
- name: setup node
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}
uses: actions/setup-node@v2
- name: Install dependencies
env:
CI: true
run: npm ci
- name: Lint
run: npm run lint
- name: Test
run: npm run test
- name: e2e Test
run: npm run test:e2e
5 changes: 5 additions & 0 deletions jest-puppeteer.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
module.exports = {
server: {
command: 'npm run serve',
},
};
Loading