Skip to content

Commit

Permalink
add simulator test
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexanderVNikitin committed Nov 17, 2023
1 parent 6bcca31 commit 35dbba6
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions tests/test_simulator.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
import pytest

import networkx as nx

import numpy as np
import tsgm


Expand All @@ -23,3 +20,10 @@ def test_sine_cosine_simulator():
params1 = sin_cosine_sim.params()
params2 = new_sim.params()
assert params1.keys() == params2.keys() and params1["max_scale"] == params2["max_scale"] and params1["max_const"] == params2["max_const"]


def test_simulator_base():
data = tsgm.dataset.Dataset(x=np.ones((3, 2, 1)), y=np.ones(3))
s = tsgm.simulator.Simulator(data)
cloned = s.clone()
assert np.array_equal(s._data.X, cloned._data.X) and np.array_equal(s._data.y, cloned._data.y)

0 comments on commit 35dbba6

Please sign in to comment.