-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Figure out static checks for TypeScript/Next.js portion of the app (#23)
Adding: * next lint for catching JS errors, and adding it to the pre-commit hook and static code checks github action. * prettier for UI code format, and adding it to the pre-commit hook and static code checks github action * jest for testing, and adding it to the unit test github action * Adding one sample unit test for page.tsx * Adding instructions on how to run front-end tests * Adding autofix commit bots as per * Enable pre-commit ci and add default config aieng-template#10 * Adding unit test runs in pre-commit hooks * Deleting package-lock.json, we don't need it since we use yarn and it has yarn-lock.json.
- Loading branch information
Showing
20 changed files
with
2,906 additions
and
7,756 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
**/node_modules/** | ||
**/.next/** | ||
tsconfig.json | ||
*.min.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -56,6 +56,15 @@ jobs: | |
source $(poetry env info --path)/bin/activate | ||
poetry install --with docs,test | ||
coverage run -m pytest florist/tests/integration && coverage xml && coverage report -m | ||
# TODO enable this once we have intergation tests for the UI | ||
# - name: Setup yarn | ||
# uses: mskelton/setup-yarn@v1 | ||
# - name: Install nextjs dependencies and check code | ||
# run: | | ||
# yarn | ||
# yarn integration-test | ||
|
||
# - name: Upload coverage to Codecov | ||
# uses: Wandalen/[email protected] | ||
# with: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -42,12 +42,19 @@ jobs: | |
- uses: actions/[email protected] | ||
with: | ||
python-version: '3.9' | ||
- name: Install dependencies and check code | ||
cache: 'poetry' | ||
- name: Install python dependencies and check code | ||
run: | | ||
poetry env use '3.9' | ||
source $(poetry env info --path)/bin/activate | ||
poetry install --with docs,test | ||
coverage run -m pytest florist/tests/unit && coverage xml && coverage report -m | ||
- name: Setup yarn | ||
uses: mskelton/setup-yarn@v1 | ||
- name: Install nextjs dependencies and check code | ||
run: | | ||
yarn | ||
yarn unit-test | ||
# - name: Upload coverage to Codecov | ||
# uses: Wandalen/[email protected] | ||
# with: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
florist/app/assets/css/material-dashboard.css | ||
*.min.js |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
{ | ||
"tabWidth": 4 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.