Skip to content

Commit

Permalink
test ids in surface domains
Browse files Browse the repository at this point in the history
  • Loading branch information
jhdark committed Oct 10, 2023
1 parent fcac4fc commit 26dde3b
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions test/test_subdomains.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,24 @@
import festim as F


def test_different_surface_ids():
my_model = F.HydrogenTransportProblem()

L = 3e-02
my_model.mesh = F.Mesh1D(np.linspace(0, L, num=3))

surfacec_subdomains_ids = [3, 8]
surface_subdomain_1 = F.SurfaceSubdomain1D(id=surfacec_subdomains_ids[0], x=0)
surface_subdomain_2 = F.SurfaceSubdomain1D(id=surfacec_subdomains_ids[1], x=L)
my_model.subdomains = [surface_subdomain_1, surface_subdomain_2]

my_model.define_function_space()
my_model.define_markers_and_measures()

for surf_id in surfacec_subdomains_ids:
assert surf_id in np.array(my_model.facet_meshtags.values)


def test_different_volume_ids():
my_model = F.HydrogenTransportProblem()

Expand Down

0 comments on commit 26dde3b

Please sign in to comment.