Skip to content

Commit

Permalink
Merge pull request #2 from MaartenStaa/tests-and-reorg
Browse files Browse the repository at this point in the history
Add tests, benchmarks, re-organize code and optimize some parts
  • Loading branch information
MaartenStaa authored Sep 26, 2023
2 parents bb1ceaa + 3a39bf7 commit eb2b818
Show file tree
Hide file tree
Showing 17 changed files with 35,974 additions and 124 deletions.
32 changes: 24 additions & 8 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,37 @@ name: Rust

on:
push:
branches: [ "main" ]
branches: ["main"]
pull_request:
branches: [ "main" ]
branches: ["main"]

env:
CARGO_TERM_COLOR: always

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose
- uses: actions/checkout@v3
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose
- name: Run benchmarks
run: cargo bench -p file_web_devicon_lib -- --output-format bencher | tee bench-output.txt
- name: Download previous benchmark data
uses: actions/cache@v1
with:
path: ./cache
key: ${{ runner.os }}-benchmark
- name: Store benchmark result
uses: benchmark-action/github-action-benchmark@v1
with:
tool: "cargo"
output-file-path: bench-output.txt
external-data-json-path: ./cache/benchmark-data.json
fail-on-alert: true
github-token: ${{ secrets.GITHUB_TOKEN }}
comment-on-alert: true
summary-always: true
Loading

0 comments on commit eb2b818

Please sign in to comment.