Skip to content

Commit feeba9e

Browse files
committed
add github action
1 parent 4984741 commit feeba9e

File tree

3 files changed

+37
-2
lines changed

3 files changed

+37
-2
lines changed
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Python tests
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
pull_request:
7+
branches: ["main"]
8+
9+
jobs:
10+
build:
11+
runs-on: macos-14
12+
strategy:
13+
fail-fast: false
14+
matrix:
15+
python-version: ["3.10", "3.11", "3.12"]
16+
17+
steps:
18+
- uses: actions/checkout@v4
19+
- name: Set up Python ${{ matrix.python-version }}
20+
uses: actions/setup-python@v3
21+
with:
22+
python-version: ${{ matrix.python-version }}
23+
- name: Install poetry
24+
run: pipx install poetry
25+
- name: Install dependencies
26+
run: |
27+
brew install cairo
28+
poetry env use python${{ matrix.python-version }}
29+
poetry install
30+
- name: Lint with flake8
31+
run: |
32+
poetry run flake8
33+
- name: Lint with black
34+
run: poetry run black --check .
35+
- name: Test with pytest
36+
run: |
37+
poetry run pytest

mapsy/icon/icon.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
from dataclasses import dataclass
2-
import os
32
from pathlib import Path
43

54
from mapsy.common import IconAlign

test/util.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import pytest
21
import mapsy
32
from contextlib import contextmanager
43
from os import path

0 commit comments

Comments
 (0)