We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
test_throws
1 parent f31c4a4 commit 3f01acdCopy full SHA for 3f01acd
test/test_initial_errors.jl
@@ -5,10 +5,13 @@ using Zygote
5
# Before defining OperatorEnum, calling the implicit (deprecated)
6
# syntax should fail:
7
tree = Node(; feature=1)
8
-@test_throws ErrorException tree([1.0 2.0]')
9
-@test_throws "Please use the " tree([1.0 2.0]')
10
-@test_throws ErrorException tree'([1.0 2.0]')
11
-@test_throws "Please use the " tree'([1.0 2.0]')
+
+if VERSION >= v"1.8"
+ @test_throws ErrorException tree([1.0 2.0]')
+ @test_throws "Please use the " tree([1.0 2.0]')
12
+ @test_throws ErrorException tree'([1.0 2.0]')
13
+ @test_throws "Please use the " tree'([1.0 2.0]')
14
+end
15
16
@test string(tree) == "x1"
17
@test string(Node(1, tree)) == "unary_operator[1](x1)"
0 commit comments