-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3 from TranslatorSRI/stub
Stub part 2
- Loading branch information
Showing
7 changed files
with
152 additions
and
99 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,46 @@ | ||
name: 'Pull Request Feedback' | ||
|
||
on: | ||
pull_request: | ||
|
||
jobs: | ||
test: | ||
name: Run pytest | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout the repository | ||
uses: actions/checkout@v2 | ||
|
||
# Cache docker layers for faster build | ||
- uses: satackey/[email protected] | ||
# Ignore the failure of a step and avoid terminating the job. | ||
continue-on-error: true | ||
|
||
- name: Build | ||
run: docker build -t appraiser-testing -f Dockerfile.test . | ||
|
||
- name: Run tests and get output | ||
run: | | ||
echo 'TEST_OUTPUT<<EOF' >> $GITHUB_ENV | ||
echo "$(docker run appraiser-testing)" >> $GITHUB_ENV | ||
echo 'EOF' >> $GITHUB_ENV | ||
- name: Exit if there are any test failures | ||
run: '[[ $TEST_OUTPUT != *FAILED* ]]' | ||
|
||
verify-lock: | ||
name: Verify lockfiles are up to date | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout the repository | ||
uses: actions/checkout@v2 | ||
|
||
- name: Verify lockfiles | ||
run: python manage.py verify_locked | ||
|
||
check-format: | ||
name: Check that code matches Black formatter | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: psf/black@stable |
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,21 @@ | ||
FROM renciorg/renci-python-image:v0.0.1 | ||
|
||
# Add image info | ||
LABEL org.opencontainers.image.source /github.com/TranslatorSRI/answer-appraiser | ||
|
||
# set up requirements | ||
WORKDIR /app | ||
|
||
# Normal requirements | ||
ADD requirements-lock.txt . | ||
RUN pip install -r requirements-lock.txt | ||
|
||
# Test requirements | ||
ADD requirements-test-lock.txt . | ||
RUN pip install -r requirements-test-lock.txt | ||
|
||
# Copy in files | ||
ADD . . | ||
|
||
# set up default command | ||
CMD pytest |
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
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
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