-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
test: Add CodSpeed to follow lib performance
- Loading branch information
Showing
13 changed files
with
95 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -15,6 +15,8 @@ on: | |
- feat/* | ||
- hotfix/* | ||
- main | ||
# Allows CodSpeed to trigger backtest performance analysis in order to generate initial data | ||
workflow_dispatch: | ||
|
||
jobs: | ||
init: | ||
|
@@ -104,7 +106,10 @@ jobs: | |
run: echo "${{ secrets.DOTENV_UNIT_TESTS }}" > .env | ||
|
||
- name: Run tests | ||
run: make test-${{ matrix.step }} version_full=${{ needs.init.outputs.VERSION_FULL }} | ||
uses: CodSpeedHQ/[email protected] | ||
with: | ||
token: ${{ secrets.CODSPEED_TOKEN }} | ||
run: make test-${{ matrix.step }} version_full=${{ needs.init.outputs.VERSION_FULL }} | ||
|
||
- name: Upload artifacts | ||
uses: actions/[email protected] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -291,3 +291,6 @@ test-reports/ | |
# Local .env | ||
!.env.example | ||
.env.* | ||
|
||
# CodSpeed | ||
.codspeed/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,17 @@ | ||
from os import environ as env | ||
|
||
from dotenv import find_dotenv, load_dotenv | ||
|
||
# First, load the environment variables from the .env file | ||
load_dotenv( | ||
find_dotenv( | ||
# Use the current working directory from where the command is run | ||
usecwd=True, | ||
) | ||
) | ||
|
||
# Detect if the code is running in a CI environment | ||
# See: https://stackoverflow.com/a/75223617 | ||
IS_CI = env.get("CI", "").lower() == "true" | ||
if IS_CI: | ||
print("CI environment detected, be aware configuration may differ") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.