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.
1 parent 65475bf commit a575e0bCopy full SHA for a575e0b
test/unittests.jl
@@ -28,5 +28,12 @@ using Unitful: Unitful
28
@inferred base_numeric_type(1.5DynamicQuantities.u"km/s")
29
end
30
31
-@test base_numeric_type(1.5DynamicQuantities.u"km/s") == base_numeric_type(typeof(1.5DynamicQuantities.u"km/s"))
32
-@inferred base_numeric_type(1.5DynamicQuantities.u"km/s")
+@testset "Nested types" begin
+ # Quantity ∘ Measurement:
33
+ x = 5Unitful.u"m/s" ± 0.1Unitful.u"m/s"
34
+ @test base_numeric_type(x) == Float64
35
+
36
+ # Quantity ∘ Dual:
37
+ y = Dual(1.0)Unitful.u"m/s"
38
+ @test base_numeric_type(y) == Float64
39
+end
0 commit comments