forked from zedeus/nitter
-
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.
Add actions workflow to run Selenium tests (zedeus#818)
- Loading branch information
Showing
3 changed files
with
44 additions
and
1 deletion.
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
name: CI/CD | ||
name: Docker | ||
|
||
on: | ||
push: | ||
|
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,42 @@ | ||
name: Run tests | ||
|
||
on: | ||
push: | ||
paths-ignore: | ||
- "*.md" | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 | ||
- name: Cache nimble | ||
id: cache-nimble | ||
uses: actions/cache@v3 | ||
with: | ||
path: ~/.nimble | ||
key: nimble-${{ hashFiles('*.nimble') }} | ||
restore-keys: "nimble-" | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10" | ||
cache: "pip" | ||
- uses: jiro4989/setup-nim-action@v1 | ||
with: | ||
nim-version: "1.x" | ||
- run: nimble build -d:release -Y | ||
- run: pip install seleniumbase | ||
- run: seleniumbase install chromedriver | ||
- uses: supercharge/[email protected] | ||
- name: Prepare Nitter | ||
run: | | ||
sudo apt install libsass-dev -y | ||
cp nitter.example.conf nitter.conf | ||
nimble md | ||
nimble scss | ||
- name: Run tests | ||
run: | | ||
./nitter & | ||
pytest -n4 tests |
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 @@ | ||
seleniumbase |