Skip to content

Commit

Permalink
typo
Browse files Browse the repository at this point in the history
  • Loading branch information
aplavin authored Feb 27, 2024
1 parent a3248c2 commit f20a158
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions test/test_functionlenses.jl
Original file line number Diff line number Diff line change
Expand Up @@ -111,13 +111,13 @@ end
test_getset_laws(Accessors.getproperties, 1+2im, (im=4., re=3.), (re=5, im=6); cmp=cmp)

@testset for obj in [(10, 20.), (x=10, y=20.)]
@test (@set propertynames(obj) == 1:2) === obj
@test (@set propertynames(obj) == (:a, :b)) === (a=10, b=20.)
@test_throws Exception (@set propertynames(obj) == 1:3)
@test_throws Exception (@set propertynames(obj) == (2, 3))
@test_throws Exception (@set propertynames(obj) == (:a, :b, :c))
@test_throws Exception (@set propertynames(obj) == (1, :b))
@test_throws Exception (@set propertynames(obj) == ("a", "b"))
@test (@set propertynames(obj) = 1:2) === obj
@test (@set propertynames(obj) = (:a, :b)) === (a=10, b=20.)
@test_throws Exception (@set propertynames(obj) = 1:3)
@test_throws Exception (@set propertynames(obj) = (2, 3))
@test_throws Exception (@set propertynames(obj) = (:a, :b, :c))
@test_throws Exception (@set propertynames(obj) = (1, :b))
@test_throws Exception (@set propertynames(obj) = ("a", "b"))
end
test_getset_laws(propertynames, (10, 20.), (:a, :b), (1, 2); cmp=(===))
test_getset_laws(propertynames, (10, 20.), (1, 2), (:a, :b); cmp=(===))
Expand Down

0 comments on commit f20a158

Please sign in to comment.