From dd4cdb22573a2f5f47b322727ff9b6477737cd90 Mon Sep 17 00:00:00 2001 From: ksagiyam Date: Fri, 8 Nov 2024 11:07:54 +0000 Subject: [PATCH 1/2] DROP BEFORE MERGE --- .github/workflows/build.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0fff428f43..358466ad97 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -83,6 +83,7 @@ jobs: --install defcon \ --install gadopt \ --install asQ \ + --package-branch tsfc ksagiyam/attach_dtype_to_nodes \ || (cat firedrake-install.log && /bin/false) - name: Install test dependencies run: | From 6c1e311e39612405608a0d29db26da2f34a44c40 Mon Sep 17 00:00:00 2001 From: ksagiyam Date: Mon, 11 Nov 2024 14:30:50 +0000 Subject: [PATCH 2/2] test: add test for 0**{min_value, max_value} --- tests/regression/test_assemble.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/regression/test_assemble.py b/tests/regression/test_assemble.py index 9ee0e1d9e7..bd8f020e60 100644 --- a/tests/regression/test_assemble.py +++ b/tests/regression/test_assemble.py @@ -334,3 +334,13 @@ def test_assemble_sparsity_diagonal_entries_for_bc(): A = assemble(inner(u[1], v[0]) * dx, bcs=[bc], mat_type="nest") # Make sure that diagonals are allocated. assert np.all(A.M.sparsity[1][1].nnz == np.ones(4, dtype=IntType)) + + +@pytest.mark.skipcomplex +def test_assemble_power_zero_minmax(): + mesh = UnitSquareMesh(1, 1) + V = FunctionSpace(mesh, "CG", 1) + f = Function(V).assign(1.) + g = Function(V).assign(2.) + assert assemble(zero()**min_value(f, g) * dx) == 0.0 + assert assemble(zero()**max_value(f, g) * dx) == 0.0