I am stuck at this exercise and I don’t know what I did wrong. when I run testSection[`exercise1], it fails for 1.3 and says “check if all values are correct”. When I run the test function, it gives the following error message:
2 of 2 tests failed
Failed Tests : 2
feature .f1.createLapTable
should Each Sensor Should Have Start Time From Lap Table
expect (AdvancedCapstone.Functions.test/.f1.createLapTable.quke:6)
Expect Error: type
should Each Sensor Should Have End Time From Lap Table
expect (AdvancedCapstone.Functions.test/.f1.createLapTable.quke:9)
Expect Error: type
Also, am I supposed to run the function on the scratchpad before using testsection? If so, then do I run it with the entire event and sensor tables?
For reference, here is my code:
.f1.createLapTable:{[eventTab;sensorTab]
distinctSensors: distinct select sensorId from sensorTab;
crosspdt:(select from eventTab) cross distinctSensors;
windows:(crosspdt[time];crosspdt[
endTime]);
p:wj[windows;date
sensorIdtime;select from crosspdt;(select from sensorTab;(avg;
sensorValue))];
delete date from p;
}
Please help me with this query.