-
Notifications
You must be signed in to change notification settings - Fork 102
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add code style check and fix commands
Add code style check and fix commands
- Loading branch information
1 parent
b39823e
commit 1a3f738
Showing
3 changed files
with
35 additions
and
16 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 |
---|---|---|
@@ -1,44 +1,55 @@ | ||
name: Tests | ||
on: push | ||
jobs: | ||
code-style: | ||
name: Code style | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.8 | ||
cache: 'pip' | ||
- run: pip install -r requirements.txt | ||
- name: Check | ||
run: black . --check | ||
|
||
duplicates: | ||
name: No duplicate domains in list | ||
runs-on: ubuntu-latest | ||
continue-on-error: true | ||
steps: | ||
- uses: actions/checkout@v2 | ||
name: Python setup | ||
- uses: actions/setup-python@v2 | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.8 | ||
- name: Install pytest | ||
run: pip install pytest | ||
cache: 'pip' | ||
- run: pip install -r requirements.txt | ||
- name: Check for duplicate lines | ||
run: | | ||
cd scripts | ||
python3 tests.py --type duplicates | ||
regex: | ||
name: No regex domains in list | ||
runs-on: ubuntu-latest | ||
continue-on-error: true | ||
steps: | ||
- uses: actions/checkout@v2 | ||
name: Python setup | ||
- uses: actions/setup-python@v2 | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.8 | ||
- name: Install pytest | ||
run: pip install pytest | ||
cache: 'pip' | ||
- run: pip install -r requirements.txt | ||
- name: Check if list includes regex domains | ||
run: | | ||
cd scripts | ||
python3 tests.py --type regex | ||
unbound: | ||
name: Check Unbound list | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/checkout@v4 | ||
- name: Install Unbound | ||
run: sudo apt-get update && sudo apt-get install -y unbound | ||
- name: Check unbound list | ||
run: unbound-checkconf unbound.conf | ||
run: unbound-checkconf unbound.conf |
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 |
---|---|---|
@@ -1,2 +1,4 @@ | ||
black==24.8.0 | ||
python-whois==0.9.4 | ||
dnspython==2.6.1 | ||
dnspython==2.6.1 | ||
pytest==8.3.2 |