Lucidarch Lucid Versions Save

Build scalable Laravel apps without compromising code quality and the least amount of technical debt. Effortless code navigation, onboarding and reviews. Tailored for Microservices and mindful of Monoliths.

v1.0.11

2 years ago

Added

  • Support unit instances with mocks

We can now mock unit instances that are written with the new PHP syntax the same as we did with the previous class string syntax:

$repo = $this->run(new GetGitHubRepoJob(id: $repoId, withReleases: false));
GetGitHubRepoJob::mock([
  'id' => 'some-id-here',
  'withReleases' => false,
])->shouldReturn($sampleRepo);

v1.0.10

2 years ago

Fixed

  • Broken run for PHP < 8 due to mixed param hinting

v1.0.9

2 years ago

Changed

  • UnitDispatcher::run's signature changed to use mixed for $unit to help IDEs tolerate passing instances instead of strings only; best used for named parameters in PHP 8
  • use full Lang & View facades namespaces in service providers for Laravel 8

v1.0.8

2 years ago

Added

  • Support generating features in subdirectories. More in Features docs

v1.0.7

2 years ago

Added

  • Unit self mocking for easier testing capabilities. See details in the docs (implementation courtesy of @IlliaBalia)

v1.0.6

2 years ago

Fixed

  • Service database seeders directory name: was seeds now it's seeders similar to Laravel's. e.g. app/Services/Chat/database/seeders

Added

  • Readme: ToC & contribution guide

1.0.5

2 years ago

Fixed

  • Generating Feature tests in their correct location tests/Feature/Services/{service}/*FeatureTest.php & tests/Feature/*FeatureTest.php

v1.0.4

3 years ago

Changed

  • Services in migrations are now optional. It is possible to call lucid migrate with no arguments which acts the same as Laravel's. Thanks to #22 @Batisska
  • Resolve units using the app container within the dispatcher (features, jobs, operations). Thanks to #17 @IlliaBalia

Fixed

  • CI test paths

v1.0.3

3 years ago

Changed

  1. Tests will no longer be located away from the root tests directory, and will be distributed to tests/Feature and tests/Unit
Unit From To
Feature tests/Features/*Test.php tests/Feature/*Test.php
app/Services/<service>/Tests/*Test.php tests/Feature/Services/<service>/*Test.php
Operation tests/Operations/*Test.php tests/Unit/Operations/*Test.php
app/Services/<service>/Tests/Operations/*Test.php tests/Unit/Services/<service>/Operations/*Test.php
Job app/Domains/<domain>/Tests/Jobs/*Test.php tests/Unit/Domains/<domain>/Jobs/*Test.php
  1. Use proper namespaces for test files starting with Tests\... instead of App\..\Tests\...

Fixed

  • Default test method names are generated using Str::snake instead of mb_strtolower (test_someawesomefeature -> test_some_awesome_feature for a feature called SomeAwesomeFeature)

v1.0.2

3 years ago

Fixed

Thanks to @undjike for reporting #1

  • Locating source directory
  • Determining project variant (Micro or Monolith)