Skip to content

Commit 5a85467

Browse files
committed
Simplify tests
1 parent 85f9440 commit 5a85467

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

test/test_algorithmsinterfaceextensions.jl

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ end
2525

2626
function AI.step!(
2727
problem::TestProblem, algorithm::TestAlgorithmStep, state::AIE.DefaultState;
28-
logging_context_prefix = Symbol()
28+
kwargs...
2929
)
3030
state.iterate .+= 2 # Different increment step
3131
return state
@@ -58,7 +58,7 @@ end
5858
state = AIE.DefaultState(; iterate = [0.0, 0.0], stopping_criterion_state)
5959

6060
initial_iterate = [1.0, 2.0]
61-
AIE.AI.initialize_state!(problem, algorithm, state; iterate = initial_iterate)
61+
AI.initialize_state!(problem, algorithm, state; iterate = initial_iterate)
6262
@test state.iterate == initial_iterate
6363
@test state.iteration == 0
6464
end
@@ -68,7 +68,7 @@ end
6868
problem = TestProblem([1.0, 2.0])
6969
algorithm = TestAlgorithm()
7070

71-
state = AIE.AI.initialize_state(problem, algorithm; iterate = [0.0, 0.0])
71+
state = AI.initialize_state(problem, algorithm; iterate = [0.0, 0.0])
7272
@test state isa AIE.DefaultState
7373
@test state.iteration == 0
7474
end
@@ -363,14 +363,14 @@ end
363363
)
364364

365365
problem = TestProblem([1.0, 2.0])
366-
state = AIE.AI.initialize_state(problem, flattened_alg; iterate = [0.0, 0.0])
366+
state = AI.initialize_state(problem, flattened_alg; iterate = [0.0, 0.0])
367367

368368
# Manually step through to test step! functionality
369-
AIE.AI.increment!(problem, flattened_alg, state)
369+
AI.increment!(problem, flattened_alg, state)
370370
@test state.parent_iteration == 1
371371
@test state.child_iteration == 1
372372

373-
AIE.AI.step!(problem, flattened_alg, state)
373+
AI.step!(problem, flattened_alg, state)
374374
# The nested algorithm runs TestAlgorithmStep with 2 iterations, each incrementing by 2
375375
@test state.iterate [4.0, 4.0]
376376
end

0 commit comments

Comments
 (0)