diff --git a/.buildkite/testing_luxlib.yml b/.buildkite/testing_luxlib.yml index 675f9792c9..8a1607ec58 100644 --- a/.buildkite/testing_luxlib.yml +++ b/.buildkite/testing_luxlib.yml @@ -27,7 +27,7 @@ steps: Pkg.instantiate(); Pkg.activate("lib/LuxLib/test"); dev_pkgs = Pkg.PackageSpec[]; - for pkg in ("lib/LuxTestUtils", "lib/LuxLib") + for pkg in ("lib/LuxTestUtils", "lib/LuxLib", "lib/MLDataDevices") push!(dev_pkgs, Pkg.PackageSpec(path=pkg)); end; Pkg.develop(dev_pkgs)' @@ -76,7 +76,7 @@ steps: Pkg.instantiate(); Pkg.activate("lib/LuxLib/test"); dev_pkgs = Pkg.PackageSpec[]; - for pkg in ("lib/LuxTestUtils", "lib/LuxLib") + for pkg in ("lib/LuxTestUtils", "lib/LuxLib", "lib/MLDataDevices") push!(dev_pkgs, Pkg.PackageSpec(path=pkg)); end; Pkg.develop(dev_pkgs)' diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index c53f2acc7a..5bc080187f 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -9,6 +9,11 @@ on: - "test/**" - "Project.toml" - ".github/workflows/CI.yml" + - "lib/LuxTestUtils/**" + - "lib/LuxCore/**" + - "lib/MLDataDevices/**" + - "lib/WeightInitializers/**" + - "lib/LuxLib/**" push: branches: - main @@ -30,6 +35,8 @@ jobs: - "1.10" os: - ubuntu-latest + - macos-latest + - windows-latest test_group: - "core_layers" - "contrib" @@ -42,13 +49,6 @@ jobs: - "eltype_match" - "fluxcompat" - "reactant" - include: - - version: "1.10" - os: macos-latest - test_group: "all" - - version: "1.10" - os: windows-latest - test_group: "all" steps: - uses: actions/checkout@v4 - uses: julia-actions/setup-julia@v2 @@ -64,8 +64,29 @@ jobs: ${{ runner.os }}-test-${{ env.cache-name }}- ${{ runner.os }}-test- ${{ runner.os }}- - - uses: julia-actions/julia-buildpkg@v1 - - uses: julia-actions/julia-runtest@v1 + - name: "Install Dependencies" + run: | + import Pkg + dev_pkgs = Pkg.PackageSpec[] + for pkg in ("lib/LuxCore", "lib/MLDataDevices", "lib/WeightInitializers", "lib/LuxLib",) + push!(dev_pkgs, Pkg.PackageSpec(path=pkg)) + end + Pkg.develop(dev_pkgs) + Pkg.Registry.update() + Pkg.instantiate() + Pkg.activate("test") + dev_pkgs = Pkg.PackageSpec[] + for pkg in ("lib/LuxTestUtils", "lib/LuxLib", "lib/MLDataDevices", "lib/LuxCore", ".") + push!(dev_pkgs, Pkg.PackageSpec(path=pkg)) + end + Pkg.develop(dev_pkgs) + shell: julia --color=yes --code-coverage=user --depwarn=yes --project=. {0} + - name: "Run Tests" + run: | + import Pkg, Lux + dir = dirname(pathof(Lux)) + include(joinpath(dir, "../test/runtests.jl")) + shell: julia --color=yes --code-coverage=user --depwarn=yes --project=test {0} env: LUX_TEST_GROUP: ${{ matrix.test_group }} - uses: julia-actions/julia-processcoverage@v1 @@ -80,7 +101,6 @@ jobs: downgrade: if: ${{ !contains(github.event.head_commit.message, '[skip tests]') && github.base_ref == github.event.repository.default_branch }} - name: Downgrade Julia 1.10 runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -88,8 +108,31 @@ jobs: with: version: "1.10" - uses: julia-actions/julia-downgrade-compat@v1 - - uses: julia-actions/julia-buildpkg@v1 - - uses: julia-actions/julia-runtest@v1 + with: + skip: "LuxCore,MLDataDevices,WeightInitializers,LuxLib" + - name: "Install Dependencies" + run: | + import Pkg + dev_pkgs = Pkg.PackageSpec[] + for pkg in ("lib/LuxCore", "lib/MLDataDevices", "lib/WeightInitializers", "lib/LuxLib",) + push!(dev_pkgs, Pkg.PackageSpec(path=pkg)) + end + Pkg.develop(dev_pkgs) + Pkg.Registry.update() + Pkg.instantiate() + Pkg.activate("test") + dev_pkgs = Pkg.PackageSpec[] + for pkg in ("lib/LuxTestUtils", "lib/LuxLib", "lib/MLDataDevices", "lib/LuxCore", ".") + push!(dev_pkgs, Pkg.PackageSpec(path=pkg)) + end + Pkg.develop(dev_pkgs) + shell: julia --color=yes --code-coverage=user --depwarn=yes --project=. {0} + - name: "Run Tests" + run: | + import Pkg, Lux + dir = dirname(pathof(Lux)) + include(joinpath(dir, "../test/runtests.jl")) + shell: julia --color=yes --code-coverage=user --depwarn=yes --project=test {0} - uses: julia-actions/julia-processcoverage@v1 with: directories: src,ext diff --git a/.github/workflows/CIPreRelease.yml b/.github/workflows/CIPreRelease.yml index 610bb7a44a..11a05b9f68 100644 --- a/.github/workflows/CIPreRelease.yml +++ b/.github/workflows/CIPreRelease.yml @@ -1,4 +1,4 @@ -name: CIPreRelease +name: CIPreRelease (Lux) on: pull_request: branches: @@ -9,6 +9,11 @@ on: - "test/**" - "Project.toml" - ".github/workflows/CI.yml" + - "lib/LuxTestUtils/**" + - "lib/LuxCore/**" + - "lib/MLDataDevices/**" + - "lib/WeightInitializers/**" + - "lib/LuxLib/**" push: branches: - main diff --git a/.github/workflows/CI_LuxLib.yml b/.github/workflows/CI_LuxLib.yml index 9f3b227a0d..2ba26a789c 100644 --- a/.github/workflows/CI_LuxLib.yml +++ b/.github/workflows/CI_LuxLib.yml @@ -163,6 +163,8 @@ jobs: with: version: "1.10" - uses: julia-actions/julia-downgrade-compat@v1 + with: + skip: "LuxCore,MLDataDevices" - name: "Install Dependencies" run: | import Pkg @@ -175,7 +177,7 @@ jobs: Pkg.instantiate() Pkg.activate("lib/LuxLib/test") dev_pkgs = Pkg.PackageSpec[] - for pkg in ("lib/LuxTestUtils", "lib/LuxLib") + for pkg in ("lib/LuxTestUtils", "lib/LuxLib", "lib/MLDataDevices") push!(dev_pkgs, Pkg.PackageSpec(path=pkg)) end Pkg.develop(dev_pkgs)