Пример #1
0
    def initialize_temporary(cls):
        cls._temporary_database_file_path = os.path.join(os.path.dirname(Database.get_database_file_path()),
                                                         DarkMediaConstants.TEMPORARY_DB_FILE_NAME)

        super().initialize_temporary()

        Base.metadata.create_all(cls._temporary_engine)
Пример #2
0
    def initialize(cls):
        cls._database_file_path = os.path.join(os.path.dirname(Database.get_database_file_path()),
                                               DarkMediaConstants.DB_FILE_NAME)

        super().initialize()

        Base.metadata.create_all(cls._engine)