-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Vishnu Challa <[email protected]>
- Loading branch information
Vishnu Challa
committed
Aug 1, 2024
1 parent
f023a1c
commit 3dc06a2
Showing
6 changed files
with
87 additions
and
5 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,20 @@ | ||
name: Builders | ||
on: | ||
workflow_call: | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: ["3.11"] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v3 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: build and install | ||
run: | | ||
pip install . |
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,23 @@ | ||
name: CI tests | ||
on: | ||
push: | ||
branches: | ||
- master | ||
- main | ||
pull_request: | ||
branches: | ||
- master | ||
- main | ||
|
||
jobs: | ||
lint: | ||
uses: ./.github/workflows/pylint.yaml | ||
|
||
build: | ||
uses: ./.github/workflows/builders.yaml | ||
|
||
tests: | ||
needs: build | ||
uses: ./.github/workflows/tests.yaml | ||
secrets: inherit | ||
|
File renamed without changes.
11 changes: 6 additions & 5 deletions
11
.github/workflows/pylint.yml → .github/workflows/pylint.yaml
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,25 +1,26 @@ | ||
name: Pylint | ||
|
||
on: [push,pull_request] | ||
|
||
on: | ||
workflow_call: | ||
jobs: | ||
build: | ||
lint: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: ["3.11"] | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Set up Python ${{ matrix.python-version }} | ||
uses: actions/setup-python@v3 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install pylint | ||
pip install -r requirements.txt | ||
pip install . | ||
- name: Analysing the code with pylint | ||
run: | | ||
pylint -d C0103 -d R0912 $(git ls-files '*/*.py' '*.py') |
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,25 @@ | ||
name: Execute tests | ||
on: | ||
workflow_call: | ||
jobs: | ||
tests: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Install bats | ||
uses: bats-core/[email protected] | ||
with: | ||
bats-version: 1.10.0 | ||
support-install: false | ||
assert-install: false | ||
detik-install: false | ||
file-install: false | ||
|
||
- name: Execute Tests | ||
run: | | ||
bats -F pretty -T --print-output-on-failure test.bats | ||
env: | ||
TERM: linux | ||
ES_SERVER: ${{ secrets.ES_SERVER }} | ||
ES_INDEX: ${{ secrets.ES_INDEX }} |
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,13 @@ | ||
#!/usr/bin/env bats | ||
# vi: ft=bash | ||
# shellcheck disable=SC2086,SC2030,SC2031,SC2164 | ||
|
||
|
||
run_cmd(){ | ||
echo "$@" | ||
${@} | ||
} | ||
|
||
@test "orion test" { | ||
run_cmd orion --help | ||
} |