Skip to content

Commit 40ecfd0

Browse files
committed
add generate stub successfully with without any replaces tests
1 parent d21fdf5 commit 40ecfd0

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

tests/Feature/LaravelStubTest.php

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,3 +85,18 @@
8585
assertFileExists(__DIR__ . '/../App/new-test.php');
8686
assertFileDoesNotExist(__DIR__ . '/../App/test.stub');
8787
});
88+
89+
test('generate stub successfully with without any replaces', function () {
90+
$stub = __DIR__ . '/test.stub';
91+
92+
$generate = LaravelStub::from($stub)
93+
->to(__DIR__ . '/../App')
94+
->name('new-test')
95+
->ext('php')
96+
->moveStub()
97+
->generate();
98+
99+
assertTrue($generate);
100+
assertFileExists(__DIR__ . '/../App/new-test.php');
101+
assertFileDoesNotExist(__DIR__ . '/../App/test.stub');
102+
});

0 commit comments

Comments
 (0)