Skip to content

Commit

Permalink
setting up continuous integration
Browse files Browse the repository at this point in the history
  • Loading branch information
gregory-halverson committed Sep 28, 2024
1 parent 9f813f9 commit f585da7
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: CI

on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.11]

steps:
- name: Checkout repository
uses: actions/checkout@v3 # This is already the latest version

- name: Set up Python
uses: actions/setup-python@v4 # This is also the latest version
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install .[dev] # Use dev to install pytest
- name: Run tests
run: |
pytest
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# `sentinel_tiles` Python Package

![CI](https://github.com/JPL-Evapotranspiration-Algorithms/sentinel_tiles/actions/workflows/ci.yml/badge.svg)

The `sentinel_tiles` Python package generates raster geometries for the Sentinel version of 100km Military Grid Reference System (MGRS) tiles.

The Julia equivalent of this package is [SentinelTiles.jl](https://github.com/STARS-Data-Fusion/SentinelTiles.jl).
Expand Down
6 changes: 6 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -27,5 +27,11 @@ dependencies = [

requires-python = ">=3.11"

[project.optional-dependencies]
dev = [
"pytest>=6.0",
"pytest-cov", # For test coverage reports (optional)
]

[tool.setuptools.package-data]
sentinel_tiles = ["*.txt", "*.geojson"]
2 changes: 2 additions & 0 deletions tests/test_import_sentinel_tiles.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
def test_import_sentinel_tiles():
import sentinel_tiles

0 comments on commit f585da7

Please sign in to comment.