From ce97bd1d0dd077882e488ded7d85612c77d40b3f Mon Sep 17 00:00:00 2001 From: "David M. Hollenstein" Date: Fri, 20 Sep 2024 12:02:24 +0200 Subject: [PATCH] chore: Add GitHub actions workflow for running pytest --- .github/workflows/run-pytest.yml | 30 ++++++++++++++++++++++++++++++ README.md | 15 +++++++++++++-- 2 files changed, 43 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/run-pytest.yml diff --git a/.github/workflows/run-pytest.yml b/.github/workflows/run-pytest.yml new file mode 100644 index 0000000..0703cdc --- /dev/null +++ b/.github/workflows/run-pytest.yml @@ -0,0 +1,30 @@ +# This workflow will install the xlsxreport package and its dependencies and run pytest with a variety of Python versions +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python + +name: Run pytest +on: + push: + branches: ["develop", "feature/*", "main", "release/*"] + pull_request: + +jobs: + build: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + python-version: ["3.9", "3.10", "3.11", "3.12"] + + steps: + - uses: actions/checkout@v4.1.2 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v5.1.0 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install .[tests] + - name: Test with pytest + run: | + python -m pytest diff --git a/README.md b/README.md index e639f91..1a7edba 100644 --- a/README.md +++ b/README.md @@ -2,10 +2,21 @@ [![Project Status: Active – The project has reached a stable, usable state and is being actively developed.](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active) ![Python Version from PEP 621 TOML](https://img.shields.io/python/required-version-toml?tomlFilePath=https%3A%2F%2Fraw.githubusercontent.com%2Fhollenstein%2Fprofasta%2Fmain%2Fpyproject.toml) [![pypi](https://img.shields.io/pypi/v/xlsxreport)](https://pypi.org/project/xlsxreport) +[![Run pytest](https://github.com/hollenstein/xlsxreport/actions/workflows/run-pytest.yml/badge.svg?branch=main)](https://github.com/hollenstein/xlsxreport/actions/workflows/run-pytest.yml) **XlsxReport** is a Python library that automates the creation of formatted Excel reports from tabular data. -## About + +## Table of Contents + +- [What is XlsxReport?](#what-is-xlsxreport) +- [Getting Started with a simple example](#getting-started-with-a-simple-example) +- [Installation](#installation) + - [Setting up the application data directory](#setting-up-the-application-data-directory) + - [Installation when using Anaconda](#installation-when-using-anaconda) + + +## What is XlsxReport? Well-formatted Excel reports are important for presenting and sharing data in a clear and structured manner with collaborators, in publications, and for the manual inspection of results. However, creating these reports manually is time-consuming, tedious, and has to be repeated for every new dataset and analysis. XlsxReport was developed to streamline the process of turning tabular data into formatted Excel reports. By automating this task, XlsxReport allows the creation of consistent, publication-ready Excel reports with minimal effort. @@ -14,7 +25,7 @@ XlsxReport uses YAML template files to define the content, structure, and format XlsxReport is actively developed as part of the computational toolbox for the [Mass Spectrometry Facility](https://www.maxperutzlabs.ac.at/research/facilities/mass-spectrometry-facility) at the Max Perutz Labs (University of Vienna). The library has reached a stable state, and we are currently working on extending the documentation and adding minor feature enhancements. -## Getting started +## Getting Started with a simple example With XlsxReport, generating reproducibly formatted Excel reports from your data analysis pipeline is a breeze - simply create a YAML table template once and execute a single terminal command to create Excel reports whenever needed.