Skip to content

Commit

Permalink
Move to Github Actions
Browse files Browse the repository at this point in the history
  • Loading branch information
Wolfe1 committed Feb 22, 2021
1 parent a901309 commit 751b133
Show file tree
Hide file tree
Showing 3 changed files with 85 additions and 17 deletions.
45 changes: 45 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: "Code scanning - action"

on:
pull_request:
schedule:
- cron: '0 7 * * 1'

jobs:
CodeQL-Build:

runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
fetch-depth: 2

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
# Override language selection by uncommenting this and choosing your languages
# with:
# languages: go, javascript, csharp, python, cpp, java

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v1

# ℹ️ Command-line programs to run using the OS shell.
# 📚 https://git.io/JvXDl

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v1
40 changes: 40 additions & 0 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
name: tests
on:
push:
branches:
- master
pull_request:
branches:
- master
jobs:
run-tests:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [ 3.6, 3.7, 3.8 ]
include:
- os: ubuntu-latest
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 dependencies
run: |
python -m pip install --upgrade pip
pip install .
pip install coveralls mock pytest-cov
- name: Run Unit Tests
run: |
pytest --cov SmtpLibrary -v tests/base.py
- name: Coveralls
env:
GITHUB_TOKEN: ${{ secrets.github_token }}
flag-name: run-${{ matrix.python-version }}
parallel: true
run: |
coveralls --service=github
17 changes: 0 additions & 17 deletions .travis.yml

This file was deleted.

0 comments on commit 751b133

Please sign in to comment.