Skip to content

Commit

Permalink
Fix some broken tests
Browse files Browse the repository at this point in the history
Declaring elements without connectivity vector/tuple at all is probably
a bad idea. Better idea is to define right size vector describing
connectivity, but give zeros to those nodes which are not connected to
anywhere.
  • Loading branch information
ahojukka5 committed Nov 21, 2019
1 parent 981fd6a commit 2a0fd11
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions test/test_problems.jl
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ end
as = get_assembly(p3)
e1 = Element(Seg2, [1, 2])
e2 = Element(Seg2, [2, 3])
e3 = Element(Seg2, Int[])
e3 = Element(Seg2, [0, 0])
update!(e1, "f", [1.0, 1.0])
update!(e2, "f", [2.0, 2.0])
push!(p3, e1)
Expand Down Expand Up @@ -259,6 +259,4 @@ end
@test get_gdofs(problem, element) == [1, 2, 3, 4]
set_gdofs!(problem, element, [2, 3, 4, 5])
@test get_gdofs(problem, element) == [2, 3, 4, 5]
element2 = Element(Seg2, Int[])
@test_throws ErrorException get_gdofs(problem, element2)
end

0 comments on commit 2a0fd11

Please sign in to comment.