diff --git a/spec/models/ci/trigger_spec.rb b/spec/models/ci/trigger_spec.rb
index 1bcb673cb16438339456082b4d9f3aa83f3b80c1..92c15c13c18435e7a20b6a8c12dc391b2ca4b3ba 100644
--- a/spec/models/ci/trigger_spec.rb
+++ b/spec/models/ci/trigger_spec.rb
@@ -16,8 +16,8 @@ describe Ci::Trigger, models: true do
       expect(trigger.token).not_to be_nil
     end
 
-    it 'does not set an random token if one provided' do
-      trigger = create(:ci_trigger, project: project)
+    it 'does not set a random token if one provided' do
+      trigger = create(:ci_trigger, project: project, token: 'token')
 
       expect(trigger.token).to eq('token')
     end