v1.0.0-rc.40
This commit is contained in:
@@ -569,6 +569,22 @@ TEST_CASE("DiffractionExperiment_ImageTime","[DiffractionExperiment]") {
|
||||
REQUIRE_THROWS(x.ImportDatasetSettings(s));
|
||||
}
|
||||
|
||||
TEST_CASE("DiffractionExperiment_GridScan","[DiffractionExperiment]") {
|
||||
DiffractionExperiment x(DetJF(3));
|
||||
DatasetSettings s;
|
||||
s.NumTriggers(1).ImagesPerTrigger(89);
|
||||
s.GridScan(GridScanSettings(10, 1.0, 1.0, false, false));
|
||||
REQUIRE(s.GridScan());
|
||||
CHECK(s.GridScan()->GetNFast() == 10);
|
||||
CHECK(s.GridScan()->GetNSlow() == 1);
|
||||
CHECK(s.GridScan()->GetNElem() == 10);
|
||||
|
||||
x.ImportDatasetSettings(s);
|
||||
REQUIRE(x.GetGridScan());
|
||||
REQUIRE(x.GetGridScan()->GetNFast() == 10);
|
||||
REQUIRE(x.GetGridScan()->GetNSlow() == 9);
|
||||
}
|
||||
|
||||
TEST_CASE("DiffractionExperiment_ImageTime_EIGER","[DiffractionExperiment]") {
|
||||
DiffractionExperiment x(DetEIGER(3));
|
||||
DatasetSettings s;
|
||||
@@ -856,39 +872,6 @@ TEST_CASE("DiffractionExperiment_Appendix","") {
|
||||
REQUIRE(message.user_data == "HeaderAppendix");
|
||||
}
|
||||
|
||||
TEST_CASE("DiffractionExperiment_OmegaRotationAxis","[DiffractionExperiment]") {
|
||||
DiffractionExperiment x;
|
||||
|
||||
x.RotationAxis(Coord{-1, 0, 0});
|
||||
REQUIRE(x.GetRotationAxis().x == -1);
|
||||
REQUIRE(x.GetRotationAxis().y == 0);
|
||||
REQUIRE_THROWS(x.RotationAxis(Coord{0,0,0}));
|
||||
}
|
||||
|
||||
TEST_CASE("DiffractionExperiment_OmegaStep","[DiffractionExperiment]") {
|
||||
DiffractionExperiment x;
|
||||
StartMessage msg;
|
||||
|
||||
x.FillMessage(msg);
|
||||
REQUIRE(!x.GetGoniometer());
|
||||
REQUIRE(!msg.goniometer);
|
||||
|
||||
DatasetSettings d;
|
||||
d.Goniometer(GoniometerAxis{
|
||||
.name = "omega",
|
||||
.increment = 75.0f,
|
||||
.start = 20.0f
|
||||
});
|
||||
x.ImportDatasetSettings(d);
|
||||
|
||||
x.FillMessage(msg);
|
||||
REQUIRE(x.GetGoniometer().has_value());
|
||||
REQUIRE(msg.goniometer);
|
||||
REQUIRE(msg.goniometer->name == "omega");
|
||||
REQUIRE(msg.goniometer->increment == 75.0f);
|
||||
REQUIRE(msg.goniometer->start == 20.0f);
|
||||
}
|
||||
|
||||
TEST_CASE("DiffractionExperiment_ConversionOnFPGA","[DiffractionExperiment]") {
|
||||
DiffractionExperiment x;
|
||||
x.Mode(DetectorMode::Conversion);
|
||||
|
||||
Reference in New Issue
Block a user