summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--archaeological_finds/tests.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/archaeological_finds/tests.py b/archaeological_finds/tests.py
index 8d226e91d..1b61d49ca 100644
--- a/archaeological_finds/tests.py
+++ b/archaeological_finds/tests.py
@@ -106,7 +106,8 @@ class FindInit(ContextRecordInit):
default = {'label': "Base find"}
if not data_base.get('history_modifier'):
data_base['history_modifier'] = self.get_default_user()
- if not data_base.get('context_record'):
+ if not data_base.get('context_record') \
+ or not data_base['context_record'].pk:
data_base['context_record'] = self.get_default_context_record()
default.update(data_base)