示例#1
0
    def test_sinksmear_id_consistency(self):
        prop0 = OneToAllDWParser.create_instance()
        prop1 = OneToAllDWssParser.create_instance()
        sourcewave = MesonParser.create_instance()
        sinkwave = MesonParser.create_instance(fail_if_exists=False)

        parameters = dict()
        parameters["propagator0"] = prop0
        parameters["propagator1"] = prop1
        parameters["sourcewave"] = sourcewave
        parameters["sinkwave"] = sinkwave

        with self.assertRaises(ConsistencyError) as context:
            self.model.objects.create(**parameters)
        print(context.exception.error)
示例#2
0
    def test_gaugeconfig_id_consistency(self):
        prop0 = OneToAllDWParser.create_instance()
        clsparameters = OneToAllDWParser.get_parameters()
        clsparameters["gaugeconfig"]["config"] = (
            int(clsparameters["gaugeconfig"]["config"]) + 10)
        prop1 = OneToAllDWParser.create_instance(
            parameters=clsparameters, tree=OneToAllDWParser.get_tree())
        sourcewave = MesonParser.create_instance()
        sinkwave = MesonParser.create_instance(fail_if_exists=False)

        parameters = dict()
        parameters["propagator0"] = prop0
        parameters["propagator1"] = prop1
        parameters["sourcewave"] = sourcewave
        parameters["sinkwave"] = sinkwave

        with self.assertRaises(ConsistencyError) as context:
            self.model.objects.create(**parameters)
        print(context.exception.error)
示例#3
0
    def test_fermionaction_type_consistency(self):
        """Test that fermion action is domain wall type
        """
        propagator = OneToAllHisqParser.create_instance()
        wave = MesonParser.create_instance()

        parameters = dict(self.get_parameters())
        parameters["propagator"] = propagator
        parameters["wave"] = wave

        with self.assertRaises(ConsistencyError) as context:
            self.model.objects.create(**parameters)
        print(context.exception.error)