Skip to content

Commit

Permalink
Merge pull request #26 from wtsi-hgi/develop
Browse files Browse the repository at this point in the history
merge from develop
  • Loading branch information
mjkw31 authored Sep 26, 2023
2 parents ed30665 + 2ec5bf1 commit fc4ec4e
Show file tree
Hide file tree
Showing 57 changed files with 2,728 additions and 190 deletions.
1 change: 1 addition & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
* @altaf-ali
4 changes: 2 additions & 2 deletions .github/workflows/dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
branches: [ main, develop ]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
Expand Down Expand Up @@ -60,7 +60,7 @@ jobs:
uses: actions/checkout@v3
with:
repository: spack/spack
ref: 0707ffd4e466402bf19dff1add59eaf2b6d9154e
ref: e8658d6493887ef702dd38f0e9ee5870a1651c1e
path: spack

- name: Update PATH
Expand Down
56 changes: 56 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,20 @@ SoftPack Core - GraphQL backend service

## Installation

### External dependencies

SoftPack Core requires Python version 3.11 or greater.

This project also relies on Spack. Install that first:

``` console
$ git clone -c feature.manyFiles=true --depth 1 https://github.com/spack/spack.git
$ source spack/share/spack/setup-env.sh
```

To start the service, you will also need to configure a git repository to store
artifacts.

### Stable release

To install SoftPack Core, run this command in your
Expand Down Expand Up @@ -90,6 +104,48 @@ Run tests with [Tox][]
poetry run tox
```

To run integration tests, you need a git repository set up with token access and
a branch named after your git repo username (stripped of any @domain if your
username is an email address).

Make sure the artifacts/repo section of ~/.softpack/core/config.yml is
configured correctly:

```
artifacts:
repo:
url: https://github.com/[your-org]/development-softpack-artifacts.git
username: [your-username]
author: [your-name]
email: [your-email]
writer: [your-token]
```

Then enable the integration tests by suppling --repo to `poetry run pytest`, or
to tox like this:

```
poetry run tox -- -- --repo
```

To discover all tests and run them (skipping integration tests with no --repo):

``` console
poetry run pytest tests -sv
```

To run just the integration tests:

``` console
poetry run pytest tests/integration -sv --repo
```

To run an individual test:

``` console
poetry run pytest tests/integration/test_artifacts.py::test_clone -sv --repo
```

Run [MkDocs] server to view documentation:

``` console
Expand Down
50 changes: 43 additions & 7 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 5 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ classifiers=[
'License :: OSI Approved :: MIT License',
'Natural Language :: English',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python :: 3.11',
]
packages = [
Expand Down Expand Up @@ -48,6 +46,9 @@ singleton-decorator = "^1.0.0"
sqlalchemy = "1.4.45"
strawberry-graphql = "^0.177.1"
typer = "^0.9.0"
pytest-mock = "^3.11.1"
pytest-asyncio = "^0.21.1"
python-multipart = "^0.0.6"

[tool.poetry.group.dev]
optional = true
Expand Down Expand Up @@ -132,11 +133,13 @@ skip_gitignore = true
disallow_untyped_calls = true
disallow_untyped_defs = true
ignore_missing_imports = true
plugins = "strawberry.ext.mypy_plugin"

[tool.pytest.ini_options]
filterwarnings = [
"ignore::DeprecationWarning:starlette"
]
markers = "repo: mark test as altering a real git repo"

[build-system]
requires = ["poetry-core>=1.0.0"]
Expand Down
Loading

0 comments on commit fc4ec4e

Please sign in to comment.