From 42840b6363c24b23cab98ca7ce9afbbd66e488fc Mon Sep 17 00:00:00 2001 From: Phillip Alday Date: Tue, 16 Apr 2024 19:35:18 +0000 Subject: [PATCH] fix linreg test on julia dev (#92) * swap to central project.toml for multiple manifest/julia version life * increase n in simplelinreg test * add nightly and apple silicon to CI --- .github/workflows/ci.yml | 6 ++---- .gitignore | 1 + Project.toml | 18 ++++++++++++++++++ test/Project.toml | 16 ---------------- test/utils_and_types.jl | 5 +++-- 5 files changed, 24 insertions(+), 22 deletions(-) delete mode 100644 test/Project.toml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9943301..2b61879 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,9 +22,8 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - version: [1.9] - arch: [x64] - os: [ubuntu-22.04] # macos-10.15, windows-2019 + version: [1.9, 1] + os: [ubuntu-22.04, macos-14] steps: - name: Checkout uses: actions/checkout@v4 @@ -32,7 +31,6 @@ jobs: uses: julia-actions/setup-julia@v2 with: version: ${{ matrix.version }} - arch: ${{ matrix.arch }} - name: Cache uses: julia-actions/cache@v1 with: diff --git a/.gitignore b/.gitignore index 670fb5f..8ecc688 100644 --- a/.gitignore +++ b/.gitignore @@ -23,6 +23,7 @@ build/ # committed for packages, but should be committed for applications that require a static # environment. Manifest.toml +Manifest-v*.toml # Editor files .vscode/* diff --git a/Project.toml b/Project.toml index 0e08989..0127901 100644 --- a/Project.toml +++ b/Project.toml @@ -17,13 +17,31 @@ SpecialFunctions = "276daf66-3868-5448-9aa4-cd146d93841b" StatsBase = "2913bbd2-ae8a-5f71-8c99-4fb6c76f3a91" [compat] +Aqua = "0.5, 0.6" BSplineKit = "0.15, 0.16, 0.17" +CairoMakie = "0.11" DataFrames = "1" Distributions = "0.25" KernelDensity = "0.6.3" Makie = "0.20" MixedModels = "4.14" PrecompileTools = "1" +Random = "1" SpecialFunctions = "1, 2" +Statistics = "1" StatsBase = "0.33, 0.34" +Suppressor = "0.2" +TestSetExtensions = "3" julia = "1.9" + +[extras] +Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595" +CairoMakie = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0" +Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" +Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" +Suppressor = "fd094767-a336-5f1f-9728-57cf17d0bbfb" +Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" +TestSetExtensions = "98d24dd4-01ad-11ea-1b02-c9a08f80db04" + +[targets] +test = ["Aqua", "Test", "TestSetExtensions", "CairoMakie", "Random", "Statistics", "Suppressor"] diff --git a/test/Project.toml b/test/Project.toml deleted file mode 100644 index 0400cfa..0000000 --- a/test/Project.toml +++ /dev/null @@ -1,16 +0,0 @@ -[deps] -Aqua = "4c88cf16-eb10-579e-8560-4a9242c79595" -CairoMakie = "13f3f980-e62b-5c42-98c6-ff1f3baf88f0" -DataFrames = "a93c6f00-e57d-5684-b7b6-d8193f3e46c0" -Makie = "ee78f7c6-11fb-53f2-987a-cfe4a2b5a57a" -MixedModels = "ff71e718-51f3-5ec2-a782-8ffcbfa3c316" -Random = "9a3f8284-a2c9-5f02-9a11-845980a1fd5c" -Statistics = "10745b16-79ce-11e8-11f9-7d13ad32a3b2" -Suppressor = "fd094767-a336-5f1f-9728-57cf17d0bbfb" -Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40" -TestSetExtensions = "98d24dd4-01ad-11ea-1b02-c9a08f80db04" - -[compat] -Aqua = "0.5, 0.6" -Suppressor = "0.2" -TestSetExtensions = "3" diff --git a/test/utils_and_types.jl b/test/utils_and_types.jl index e6619f0..cccbd83 100644 --- a/test/utils_and_types.jl +++ b/test/utils_and_types.jl @@ -10,8 +10,9 @@ end @testset "Simple linear regression" begin a, b = 1, 2 - x = collect(1:10) - y = randn(MersenneTwister(42), 10) * 0.1 + n = 100 + x = 1:n + y = randn(MersenneTwister(42), n) * 0.1 @. y += a + b * x result = simplelinreg(x, y) @test result isa Tuple