| 651 | }; |
| 652 | |
| 653 | TEST_F(MutationTests, propertiesMutation) |
| 654 | { |
| 655 | auto genome = createGenomeWithMultipleCellsWithDifferentFunctions(); |
| 656 | int byteIndex = 0; |
| 657 | |
| 658 | auto data = DataDescription().addCells( |
| 659 | {CellDescription().setId(1).setCellFunction(ConstructorDescription().setGenome(genome).setGenomeCurrentNodeIndex(byteIndex)).setExecutionOrderNumber(0)}); |
| 660 | |
| 661 | _simulationFacade->setSimulationData(data); |
| 662 | for (int i = 0; i < 10000; ++i) { |
| 663 | _simulationFacade->testOnly_mutate(1, MutationType::Properties); |
| 664 | } |
| 665 | |
| 666 | auto actualData = _simulationFacade->getSimulationData(); |
| 667 | auto actualCellById = getCellById(actualData); |
| 668 | |
| 669 | auto actualConstructor = std::get<ConstructorDescription>(*actualCellById.at(1).cellFunction); |
| 670 | EXPECT_TRUE(comparePropertiesMutation(genome, actualConstructor.genome)); |
| 671 | EXPECT_EQ(byteIndex, actualConstructor.genomeCurrentNodeIndex); |
| 672 | } |
| 673 | |
| 674 | TEST_F(MutationTests, neuronDataMutation) |
| 675 | { |
nothing calls this directly
no test coverage detected