Skip to content

Commit

Permalink
fixed random seed for tests
Browse files Browse the repository at this point in the history
  • Loading branch information
bbejanov committed Jan 30, 2023
1 parent 409c663 commit a9a9de5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/sim_fo.jl
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
##################################################################################

using Random
using LinearAlgebra

function run_fo_unant_tests(model)
clear_sstate!(model)
Expand Down Expand Up @@ -161,6 +162,8 @@ function test_initdecomp_firstorder(m, rng=2001Q1:2020Q4, step=max(2, length(rng
linearize!(m)
solve!(m, solver=:firstorder)

Random.seed!(0xFF)

p = Plan(m, rng)
exog = steadystatedata(m, p)
exog[begin:first(rng)-1, m.variables] .= rand(m.maxlag, m.nvars)
Expand Down Expand Up @@ -220,6 +223,8 @@ function test_initdecomp_stackedtime(m; nonlin=!m.linear, rng=2001Q1:2024Q4, fct
linearize!(m)
solve!(m; solver)

Random.seed!(0xFF)

# test 1 - only initial conditions, no shocks
p = Plan(m, rng)
exog = steadystatedata(m, p)
Expand Down

0 comments on commit a9a9de5

Please sign in to comment.