Skip to content

Commit

Permalink
s
Browse files Browse the repository at this point in the history
  • Loading branch information
jere8184 committed Dec 9, 2024
1 parent e880a0a commit a28ebc2
Showing 1 changed file with 6 additions and 8 deletions.
14 changes: 6 additions & 8 deletions libopenage/curve/tests/curve_types.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@
#include <memory>
#include <string>

#include "curve/array.h"
#include "curve/continuous.h"
#include "curve/discrete.h"
#include "curve/discrete_mod.h"
#include "curve/keyframe.h"
#include "curve/keyframe_container.h"
#include "curve/segmented.h"
#include "curve/array.h"
#include "event/event_loop.h"
#include "testing/testing.h"
#include "time/time.h"
Expand Down Expand Up @@ -233,7 +233,7 @@ void curve_types() {
TESTEQUALS(c.get(8), 4);
}

//Check the discrete type
// Check the discrete type
{
auto f = std::make_shared<event::EventLoop>();
Discrete<int> c(f, 0);
Expand All @@ -258,7 +258,7 @@ void curve_types() {
TESTEQUALS(complex.get(10), "Test 10");
}

//Check the discrete mod type
// Check the discrete mod type
{
auto f = std::make_shared<event::EventLoop>();
DiscreteMod<int> c(f, 0);
Expand Down Expand Up @@ -291,7 +291,7 @@ void curve_types() {
TESTEQUALS(c.get_mod(15, 0), 0);
}

//check set_last
// check set_last
{
auto f = std::make_shared<event::EventLoop>();
Discrete<int> c(f, 0);
Expand Down Expand Up @@ -388,19 +388,17 @@ void curve_types() {
TESTEQUALS(c.get(5), 0);
}

{//array
{ // array
Array<int, 2> a;
a.set_insert(time::time_t(1), 0, 0);
a.set_insert(time::time_t(1), 1, 1);
const auto res = a.get_all(1);
TESTEQUALS(res[0], 0);
TESTEQUALS(res[1], 1);

for(auto r : a)
{
for (auto r : a) {
std::cout << r << std::endl;
}

}
}

Expand Down

0 comments on commit a28ebc2

Please sign in to comment.