Skip to content

Commit 6557f93

Browse files
committed
fix: add test for Fix1
1 parent ce866b0 commit 6557f93

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

test/interface/fix1_tests.jl

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
@testitem "Support ::Base.Fix1{typeof(logpdf), D}" begin
2+
using Distributions
3+
using ClosedFormExpectations
4+
using StableRNGs
5+
using Base.MathConstants: eulergamma
6+
7+
include("../test_utils.jl")
8+
rng = StableRNG(123)
9+
dist = Exponential(1.0)
10+
fixed_logpdf = Base.Fix1(logpdf, dist)
11+
@test mean(ClosedFormExpectation(), fixed_logpdf, Exponential(10.0)) mean(ClosedFormExpectation(), Logpdf(Exponential(1.0)), Exponential(10.0))
12+
end

0 commit comments

Comments
 (0)