diff --git a/django/db/backends/sqlite3/creation.py b/django/db/backends/sqlite3/creation.py index c334a86ac6..a9fd520b2d 100644 --- a/django/db/backends/sqlite3/creation.py +++ b/django/db/backends/sqlite3/creation.py @@ -53,7 +53,7 @@ class DatabaseCreation(BaseDatabaseCreation): def get_test_db_clone_settings(self, suffix): orig_settings_dict = self.connection.settings_dict - source_database_name = orig_settings_dict["NAME"] + source_database_name = orig_settings_dict["NAME"] or ":memory:" if not self.is_in_memory_db(source_database_name): root, ext = os.path.splitext(source_database_name)