Пример #1
0
    def test_class_definition(self):

        files = [
            './tests/placebos/test_config.yaml',
            './tests/placebos/test_second.yaml'
        ]
        test_conf_yaml = Rickle(files, deep=True, load_lambda=True)

        obj = test_conf_yaml.TesterClass()
        obj.datenow()
        obj.math_e(99, 99)
        obj.math_e()

        self.assertTrue(True)
Пример #2
0
    def test_load_dump_load(self):
        files = [
            './tests/placebos/test_config.yaml',
            './tests/placebos/test_second.yaml'
        ]
        test_conf_yaml = Rickle(files, deep=True, load_lambda=True)

        test_conf_yaml.to_yaml_file('./test_out.yaml')

        test_conf_yaml_reload = Rickle('./test_out.yaml',
                                       deep=True,
                                       load_lambda=True)

        test_conf_yaml_reload.BASICS.outer_math_e()

        obj = test_conf_yaml_reload.TesterClass()
        obj.datenow()
        obj.math_e(99, "^99>")

        os.remove('./test_out.yaml')

        self.assertTrue(True)