Skip to content

Commit 48a894e

Browse files
add tests for value function
1 parent e8e0d67 commit 48a894e

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "DiffEqBase"
22
uuid = "2b5f629d-d688-5b77-993f-72d75c75574e"
33
authors = ["Chris Rackauckas <[email protected]>"]
4-
version = "6.169.0"
4+
version = "6.169.1"
55

66
[deps]
77
ArrayInterface = "4fba245c-0d91-5ea0-9b3e-6abc04ee57a9"

test/downstream/unitful.jl

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
1-
using Unitful, OrdinaryDiffEq, Test
1+
using Unitful, OrdinaryDiffEq, ForwardDiff, Test
22
f(du, u, p, t) = du .= 3 * u"1/s" * u
33
prob = ODEProblem(f, [2.0u"m"], (0.0u"s", Inf * u"s"))
44
intg = init(prob, Tsit5())
55
@test_nowarn step!(intg, 0.02u"s", true)
6+
7+
@test DiffEqBase.unitfulvalue(u"1/s") == u"1/s"
8+
@test DiffEqBase.value(ForwardDiff.Dual(1)*u"1/s") == 1
9+
@test DiffEqBase.unitfulvalue(ForwardDiff.Dual(1)*u"1/s") == u"1/s"

0 commit comments

Comments
 (0)