2021-05-30 06:24:12 +02:00
|
|
|
name: Python Checks
|
|
|
|
on:
|
|
|
|
workflow_dispatch:
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
testing:
|
|
|
|
runs-on: ubuntu-latest
|
2021-05-30 06:52:51 +02:00
|
|
|
|
2021-05-30 06:24:12 +02:00
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
python-versions: [3.8,3.9]
|
|
|
|
|
2021-05-30 06:52:51 +02:00
|
|
|
services:
|
|
|
|
centos:
|
|
|
|
image: calebjstewart/pwncat-testing:centos
|
2021-05-30 06:55:27 +02:00
|
|
|
ports:
|
|
|
|
- 4444:4444
|
2021-05-30 06:52:51 +02:00
|
|
|
ubuntu:
|
|
|
|
image: calebjstewart/pwncat-testing:ubuntu
|
2021-05-30 06:55:27 +02:00
|
|
|
ports:
|
|
|
|
- 4445:4444
|
2021-05-30 06:52:51 +02:00
|
|
|
|
2021-05-30 06:24:12 +02:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Set up Python ${{ matrix.python-version }}
|
|
|
|
uses: actions/setup-python@v2
|
|
|
|
with:
|
|
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
- name: Install pwncat
|
|
|
|
run: |
|
|
|
|
python -m pip install --upgrade pip
|
|
|
|
pip install flake8 pytest
|
|
|
|
pip install -r requirements.txt
|
2021-05-30 06:47:23 +02:00
|
|
|
python setup.py install --user
|
2021-05-30 06:24:12 +02:00
|
|
|
# - name: Lint with flake8
|
|
|
|
# run: |
|
|
|
|
# flake8
|
|
|
|
- name: Test with pytest
|
2021-05-30 06:52:51 +02:00
|
|
|
env:
|
2021-05-30 06:57:59 +02:00
|
|
|
CENTOS_HOST: "127.0.0.1"
|
2021-05-30 06:52:51 +02:00
|
|
|
CENTOS_BIND_PORT: "4444"
|
2021-05-30 06:57:59 +02:00
|
|
|
UBUNTU_HOST: "127.0.0.1"
|
2021-05-30 06:55:27 +02:00
|
|
|
UBUNTU_BIND_PORT: "4445"
|
2021-05-30 06:24:12 +02:00
|
|
|
run: |
|
|
|
|
pytest
|