Skip to content

Commit

Permalink
chore: updated test system
Browse files Browse the repository at this point in the history
  • Loading branch information
charliekush committed Aug 7, 2024
1 parent 28c862d commit 3e2db22
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 8 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -330,4 +330,5 @@ out/docs/fw_flow/Firmware Flowchart.png
tests/googletest
tests/outputs/
build/*
tests/*outputs/*
tests/*outputs/*
tests/no_check_inputs/*
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ set(GTEST_SOURCE_FILES
src/antara_scheduler.cpp
src/charlie_scheduler.cpp
tests/fixed_google_tests.cpp
tests/file_google_tests.cpp
#tests/file_google_tests.cpp
#tests/overlap_google_tests.cpp
tests/scheduler_test_flog.cpp
)
Expand Down
3 changes: 1 addition & 2 deletions src/charlie_scheduler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,7 @@ int Scheduler::getNextTask(DeploymentSchedule_t** p_nextEvent,
{
FLOG_AddError(FLOG_SCHEDULER_DELAY_EXCEEDED,
s.measurementCount);
//SF_OSAL_printf("Task %s skipped at time %zu" __NL__ ,
//currentEvent.taskName,currentTime);

}
}
}
Expand Down
10 changes: 6 additions & 4 deletions tests/test_file_generator.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,20 +57,22 @@ def generate_delays(self):
os.remove(f)
file_num = 0
ensembles = {}
gyro_sweep = [30,31]
mag_sweep = [30,31]
gyro_sweep = [30,300]
mag_sweep = [30,300]
input = None
ensembles["Temperature"] = Ensemble("Temperature",0.873,1,1)
ensembles["GPS"] = Ensemble("GPS",0.1443,1,1)
ensembles["Wet/Dry Sensor"] = Ensemble("Wet/Dry Sensor",1.02,1,1)
for gyro_interval in range(gyro_sweep[0],gyro_sweep[1]+1):
step = 5
for gyro_interval in range(gyro_sweep[0],gyro_sweep[1]+1,step):
ensembles["Gyrometer"] = Ensemble("Gyrometer",5.209,1, gyro_interval)
for mag_interval in range(mag_sweep[0],mag_sweep[1]+1):
for mag_interval in range(mag_sweep[0],mag_sweep[1]+1,step):
ensembles["Magnetometer"] = Ensemble("Magnetometer",5.212,1, mag_interval)
input = Input("test" + str(file_num), ensembles.values())
file_num += 1
input.generate_delays()
input.write()
print(f'{file_num}/{(250/step)**2}' + "\r")



Expand Down

0 comments on commit 3e2db22

Please sign in to comment.