Fix: Perbaikan working_call #11
Workflow file for this run
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 is part of DataSae and is released under | |
# the AGPL-3.0-only License: https://opensource.org/license/agpl-v3/ | |
name: Python Application | |
on: | |
pull_request: | |
push: | |
workflow_call: | |
inputs: | |
python_version: | |
required: true | |
type: string | |
default: '3.7' | |
jobs: | |
lint: | |
name: Linter Test | |
runs-on: ubuntu-latest | |
container: | |
image: pipelinecomponents/flake8 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Lint with flake8 | |
run: flake8 | |
unittest: | |
name: Unit Test | |
runs-on: ubuntu-latest | |
if: github.event_name == 'pull_request' || contains('refs/heads/main refs/heads/develop', github.ref) | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python ${{ inputs.python_version }} | |
uses: actions/setup-python@v3 | |
with: | |
python-version: ${{ inputs.python_version }} | |
- name: Install dependencies | |
run: pip install . | |
- name: Test | |
run: python -m unittest | |
build: | |
name: Build Python Package | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set up Python ${{ inputs.python_version }} | |
uses: actions/setup-python@v3 | |
with: | |
python-version: ${{ inputs.python_version }} |