-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13 from cazana/pass-params-to-faker-commands
Pass params to faker commands
- Loading branch information
Showing
3 changed files
with
19 additions
and
55 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -47,12 +47,13 @@ public function fake_car_faker_plugin_works() | |
{ | ||
$vehicleArray = $this->transformer->transform('not required', '@vehicleArray'); | ||
$this->assertArrayHasKey('brand', $vehicleArray); | ||
$this->assertArrayHasKey('model', $vehicleArray); } | ||
$this->assertArrayHasKey('model', $vehicleArray); | ||
} | ||
|
||
/** @test */ | ||
public function max_modifier_works() | ||
public function modifiers_work() | ||
{ | ||
$this->assertEquals(8, strlen($this->transformer->transform('test', '@randomString|max:8'))); | ||
$this->assertEquals(10, $this->transformer->transform('test', '@numberBetween|10,10')); | ||
} | ||
|
||
/** @test */ | ||
|
@@ -65,6 +66,6 @@ public function static_values_work() | |
public function original_replacement_works() | ||
{ | ||
$this->assertEquals('[email protected]', $this->transformer->transform('[email protected]', '@original')); | ||
$this->assertEquals('admin@exa', $this->transformer->transform('[email protected]', '@original|max:9')); | ||
$this->assertEquals('admin@exa', $this->transformer->transform('[email protected]', '@original|9')); | ||
} | ||
} |