@Override
    public Simulation cloneModel() {
        Simulation toReturn = new Simulation();
        final List<FactMapping> originalFactMappings = this.scesimModelDescriptor.getUnmodifiableFactMappings();
        for (int i = 0; i < originalFactMappings.size(); i++) {
            final FactMapping originalFactMapping = originalFactMappings.get(i);
            toReturn.scesimModelDescriptor.addFactMapping(i, originalFactMapping);
        }
        this.scesimData.forEach(scenario -> toReturn.scesimData.add(scenario.cloneInstance()));
        return toReturn;
    }
@Test
    public void cloneModel() {
        final Simulation cloned = simulation.cloneModel();
        
        assertThat(cloned).isNotNull();
        final ScesimModelDescriptor originalDescriptor = simulation.getScesimModelDescriptor();
        final ScesimModelDescriptor clonedDescriptor = cloned.getScesimModelDescriptor();
        assertThat(clonedDescriptor.getUnmodifiableFactMappings()).hasSameSizeAs(originalDescriptor.getUnmodifiableFactMappings());
        
        assertThat(clonedDescriptor.getUnmodifiableFactMappings()).isEqualTo(originalDescriptor.getUnmodifiableFactMappings());
        
        assertThat(cloned.getUnmodifiableData()).hasSameSizeAs(simulation.getUnmodifiableData());
        assertThat(cloned.getUnmodifiableData()).usingElementComparator((x, y) -> x.getDescription().compareTo(y.getDescription())).isEqualTo(simulation.getUnmodifiableData());
    }