Skip to content

Commit

Permalink
Merge pull request #63 from albertomercurio/fix/JET
Browse files Browse the repository at this point in the history
Modify runtests and CI settings for `JET`
  • Loading branch information
albertomercurio authored Apr 8, 2024
2 parents 72890bf + 70dcdb7 commit af9b237
Show file tree
Hide file tree
Showing 8 changed files with 22 additions and 74 deletions.
54 changes: 0 additions & 54 deletions .github/workflows/CI-Code-Quality.yml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,13 @@ jobs:
group:
- Core

# for code quality tests
include:
- version: '1'
os: 'ubuntu-latest'
arch: 'x64'
group: 'Code-Quality'

steps:
- uses: actions/checkout@v4
- uses: julia-actions/setup-julia@v2
Expand All @@ -60,4 +67,4 @@ jobs:
with:
files: lcov.info
token: ${{ secrets.CODECOV_TOKEN }}
fail_ci_if_error: true
fail_ci_if_error: true
4 changes: 3 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ LinearAlgebra = "<0.0.1, 1"
LinearMaps = "3"
LinearSolve = "2"
OrdinaryDiffEq = "6"
Pkg = "<0.0.1, 1"
Random = "<0.0.1, 1"
Reexport = "1"
SparseArrays = "<0.0.1, 1"
Expand All @@ -36,7 +37,8 @@ Test = "<0.0.1, 1"
julia = "1.7"

[extras]
Pkg = "44cfe95a-1eb2-52ea-b672-e2afdf69b78f"
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

[targets]
test = ["Test"]
test = ["Pkg", "Test"]
2 changes: 2 additions & 0 deletions test/code-quality/aqua.jl → test/aqua.jl
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
using Aqua

@testset "Code quality (Aqua.jl)" begin
Aqua.test_all(QuantumToolbox; ambiguities = false,)
end
3 changes: 0 additions & 3 deletions test/code-quality/Project.toml

This file was deleted.

15 changes: 0 additions & 15 deletions test/code-quality/runtests.jl

This file was deleted.

2 changes: 2 additions & 0 deletions test/code-quality/jet.jl → test/jet.jl
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
using JET

@testset "Code quality (JET.jl)" begin
JET.test_package(QuantumToolbox; target_defined_modules=true, ignore_missing_comparison=true)
end
7 changes: 7 additions & 0 deletions test/runtests.jl
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using Test
using Pkg
using QuantumToolbox

const GROUP = get(ENV, "GROUP", "All")
Expand Down Expand Up @@ -28,3 +29,9 @@ if (GROUP == "All") || (GROUP == "Core")
include(joinpath(testdir, test))
end
end

if (GROUP == "All") || (GROUP == "Code-Quality")
Pkg.add(["Aqua", "JET"])
include(joinpath(testdir, "aqua.jl"))
include(joinpath(testdir, "jet.jl"))
end

0 comments on commit af9b237

Please sign in to comment.