Skip to content

Commit

Permalink
Merge pull request #97 from AkrilliA/feature/rename-dto-folder
Browse files Browse the repository at this point in the history
rename dto folder to data objects
  • Loading branch information
regnerisch authored Nov 29, 2023
2 parents 21153b5 + c21ad18 commit 887e4ab
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 11 deletions.
2 changes: 1 addition & 1 deletion src/Commands/MakeDataTransferObjectCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@ protected function getStub(): string

public function getType(): string
{
return 'DataTransferObject';
return 'DataObject';
}
}
2 changes: 1 addition & 1 deletion src/Commands/MakeJobCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ protected function getStub(): string
{
return match (true) {
$this->option('sync') => 'job.sync.stub',
default => 'job.stub'
default => 'job.stub'
};
}

Expand Down
1 change: 0 additions & 1 deletion tests/Commands/MakeActionCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

namespace Tests\Commands;

use Illuminate\Testing\PendingCommand;
use Tests\TestCase;

class MakeActionCommandTest extends TestCase
Expand Down
2 changes: 0 additions & 2 deletions tests/Commands/MakeCollectionCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,6 @@ public function testCanMakeCollection(): void
$this->assertStringNotContainsString('{{ className }}', $contents);
}



public function testCanMakeCollectionUsingForce(): void
{
$this->artisan('beyond:make:collection User.UserCollection');
Expand Down
8 changes: 4 additions & 4 deletions tests/Commands/MakeDataTransferObjectCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public function testCanMakeDataTransferObject(): void
{
$this->artisan('beyond:make:data User.UserData');

$file = beyond_modules_path('User/Domain/DataTransferObjects/UserData.php');
$file = beyond_modules_path('User/Domain/DataObjects/UserData.php');
$contents = file_get_contents($file);

$this->assertFileExists($file);
Expand All @@ -29,7 +29,7 @@ public function testCanMakeDataTransferObjectUsingForce(): void
{
$this->artisan('beyond:make:data User.UserData');

$file = beyond_modules_path('User/Domain/DataTransferObjects/UserData.php');
$file = beyond_modules_path('User/Domain/DataObjects/UserData.php');
$contents = file_get_contents($file);

$this->assertFileExists($file);
Expand All @@ -45,7 +45,7 @@ public function testCanMakeDataTransferWithAliasObject(): void
{
$this->artisan('beyond:make:dto User.UserData');

$file = beyond_modules_path('User/Domain/DataTransferObjects/UserData.php');
$file = beyond_modules_path('User/Domain/DataObjects/UserData.php');
$contents = file_get_contents($file);

$this->assertFileExists($file);
Expand All @@ -57,7 +57,7 @@ public function testCanMakeDataTransferWithAliasObjectUsingForce(): void
{
$this->artisan('beyond:make:dto User.UserData');

$file = beyond_modules_path('User/Domain/DataTransferObjects/UserData.php');
$file = beyond_modules_path('User/Domain/DataObjects/UserData.php');
$contents = file_get_contents($file);

$this->assertFileExists($file);
Expand Down
4 changes: 2 additions & 2 deletions tests/Commands/MakeModuleCommandTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public function testCanMakeFullModule(): void

foreach ($files as $file) {
match (Str::contains($file, '.')) {
true => $this->assertFileExists($file),
true => $this->assertFileExists($file),
false => $this->assertDirectoryExists($file),
};
}
Expand All @@ -55,7 +55,7 @@ public function testCanMakeFullModuleUsingForce(): void

foreach ($files as $file) {
match (Str::contains($file, '.')) {
true => $this->assertFileExists($file),
true => $this->assertFileExists($file),
false => $this->assertDirectoryExists($file),
};
}
Expand Down

0 comments on commit 887e4ab

Please sign in to comment.