Improve randomness in test data to prevent key collisions.

This commit is contained in:
James Cole
2018-07-14 16:41:07 +02:00
parent ff403dfa2e
commit 3d1523a060
50 changed files with 283 additions and 283 deletions

View File

@@ -45,7 +45,7 @@ class FakeRoutineTest extends TestCase
{
$job = new ImportJob;
$job->user_id = $this->user()->id;
$job->key = 'a_route_' . random_int(1, 1000);
$job->key = 'a_route_' . random_int(1, 10000);
$job->status = 'ready_to_run';
$job->stage = 'ahoy';
$job->provider = 'fake';
@@ -81,7 +81,7 @@ class FakeRoutineTest extends TestCase
{
$job = new ImportJob;
$job->user_id = $this->user()->id;
$job->key = 'a_route_' . random_int(1, 1000);
$job->key = 'a_route_' . random_int(1, 10000);
$job->status = 'ready_to_run';
$job->stage = 'final';
$job->provider = 'fake';
@@ -118,7 +118,7 @@ class FakeRoutineTest extends TestCase
{
$job = new ImportJob;
$job->user_id = $this->user()->id;
$job->key = 'a_route_' . random_int(1, 1000);
$job->key = 'a_route_' . random_int(1, 10000);
$job->status = 'ready_to_run';
$job->stage = 'new';
$job->provider = 'fake';