Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge release 3.6.0 into 4.0.x #432

Merged
merged 15 commits into from
May 3, 2024
Merged

Conversation

github-actions[bot]
Copy link

@github-actions github-actions bot commented May 2, 2024

Release Notes for 3.6.0

Feature release (minor)

3.6.0

  • Total issues resolved: 0
  • Total pull requests resolved: 7
  • Total contributors: 3

CI

Documentation

Static Analysis

Improvement

Dumkaaa and others added 15 commits December 15, 2023 15:56
Update composer dump-autoload command syntax
Running the latest PHPStan produces this output:

```
------ --------------------------------------------------------------------------------------------------------------
 Line   Loader/SymfonyFixturesLoader.php
------ --------------------------------------------------------------------------------------------------------------
 62     Call to an undefined static method Doctrine\Bundle\FixturesBundle\Loader\SymfonyBridgeLoader::addFixture().
 96     Call to an undefined static method Doctrine\Bundle\FixturesBundle\Loader\SymfonyBridgeLoader::getFixtures().
------ --------------------------------------------------------------------------------------------------------------

------ ------------------------------------------------------------------------------------------------------------------------------------------------
 Line   Tests/Command/LoadDataFixturesDoctrineCommandTest.php
------ ------------------------------------------------------------------------------------------------------------------------------------------------
 27     Class Doctrine\Bundle\FixturesBundle\Loader\SymfonyFixturesLoader does not have a constructor and must be instantiated without any parameters.
 50     Class Doctrine\Bundle\FixturesBundle\Loader\SymfonyFixturesLoader does not have a constructor and must be instantiated without any parameters.
------ ------------------------------------------------------------------------------------------------------------------------------------------------

------ ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 Line   Tests/IntegrationTest.php
------ ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
 467    Return type mixed of method Doctrine\Bundle\FixturesBundle\Tests\ForwardCompatibleEntityManager::wrapInTransaction() is not covariant with return type mixed of method Doctrine\ORM\EntityManagerInterface::wrapInTransaction().
------ ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
```

All of them happen in the context of compatibility layers. The last one
cannot be ignored for some reason.
Merge 3.5.x up into 3.6.x
Here are the steps I followed:

- `mkdir src`
- `git mv *.php src`
- `git mv Command/ DependencyInjection Loader Purger src`
- adjust autoloading path
- overrode `Bunde::getPath()`
- `git mv Resources/doc/ docs`
- `git mv Resources/config/ config`
- `git mv Tests/ tests`
The directory structure differs between both branches.
Switch to a modern directory structure
Configure docs path depending on the branch
It is now no longer required to declare groups on all dependent
fixtures, the fixture loader will now automatically find the required
dependencies and load them without them being explicitly added
to the groups being loaded.

Before you were forced to declare groups all the way down the
dependency chain, for example:

```
TopLevelFixture (groups: default)
├─ SecondLevelFixture1 (groups: default, alternative)
│  ├─ ThirdLevelFixture1 (groups: default, alternative)
├─ SecondLevelFixture2 (groups: default)
│  ├─ ThridLevelFixture2 (groups: default)
│  ├─ ThirdLevelFixture3 (groups: default, alternative)
```

Now you only need to specify the groups at the highest level:

```
TopLevelFixture (groups: default)
├─ SecondLevelFixture1 (groups: alternative)
│  ├─ ThirdLevelFixture1 (groups: none)
├─ SecondLevelFixture2 (groups: none)
│  ├─ ThridLevelFixture2 (groups: none)
│  ├─ ThirdLevelFixture3 (groups: alternative)
```

In both examples the groups `default` and `alternative` will load the
same fixtures.

Adds an additional PHPStan error to the baseline which appears to be
caused by the backwards compatibility layer.
Automatically extract fixture dependencies
Merge 3.5.x up into 3.6.x
@greg0ire greg0ire merged commit 3a3dda5 into 4.0.x May 3, 2024
15 of 22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants