Skip to content
This repository was archived by the owner on Sep 9, 2024. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 49 additions & 0 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions

name: Python Build

on:
push:
branches: [ main, develop ]
pull_request:
branches: [ main, develop ]

jobs:
build:
strategy:
fail-fast: false
max-parallel: 2
matrix:
python-version: [ "3.9", "3.10" ]
poetry-version: [ "1.1.14" ]
# os: [ ubuntu-18.04, macos-latest, windows-latest ]
os: [ ubuntu-18.04, macos-latest ]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install Poetry
uses: abatilo/actions-poetry@v2.0.0
with:
poetry-version: ${{ matrix.poetry-version }}
- name: Install dependencies
run: |
poetry install
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
poetry run flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
poetry run flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
run: |
poetry run pytest -m "not regression"
- name: Regression Test with pytest
env:
PODAAC_LOGLEVEL: "DEBUG"
run: |
poetry run pytest -o log_cli=true --log-cli-level=DEBUG -m "regression"
31 changes: 30 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,32 @@
# Unity-Py

Unity-Py is a Python client to simplify interactions with NASA's Unity Platform.
Unity-Py is a Python client to simplify interactions with NASA's Unity Platform.

## Installation

### Install from Github
```
python -m pip install git+https://github.com/unity-sds/unity-py.git
```

### Building and installing locally using poetry

```
git clone https://github.com/unity-sds/unity-py.git
cd unity-py
poetry install
```

## Testing
To run unit and regression tests:

```
# run all tests and include printouts:
poetry run pytest -s

# run non-regression tests:
poetry run pytest -m "not regression"

# run regression tests (and include logs)

```
Loading