Commit Graph

105 Commits

Author SHA1 Message Date
Loïc Frémont
b1b9b34606 Add deprecated message 2025-06-03 08:49:50 +02:00
Loïc Frémont
7fd0fb77eb Fix Mink lazy object with SF7.3 and PHP 8.4 2025-06-02 17:47:18 +02:00
Yozhef
814dc0e253 Merge pull request #213 from wuchen90/fix-bootstrap
fix: allow to use parameter resolution in configuration for bootstrap key
2025-05-27 12:31:49 +03:00
wuchen90
65cd3478b2 fix: allow to use parameter resolution in configuration for bootstrap key
In PhpStorm, I've got an issue with path resolution for the bootstrap file.
I don't know why the path in which Behat runs is always the folder `features`.
So Behat always fails trying to look for `/project/root/path/features/config/bootstrap.php`.

With this fix, bootstrap file will be resolved based on the base path.
Plus, people will be allowed to use the parameter `%paths.base%` to define a custom bootstrap file path.
E.g.:

```yaml
default:
  extensions:
    FriendsOfBehat\SymfonyExtension:
      bootstrap: '%paths.base%/custom/bootstrap.php'
```
2024-06-20 17:19:24 +02:00
Antoine Bluchet
ef60e3dd1c Http Kernel DI Extension is deprecated 2024-05-31 10:43:01 +02:00
Łukasz Chruściel
957df89b21 Merge pull request #195 from mpdude/official-mink-browserkit
Switch back to the original `behat/mink-browserkit-driver`
2023-12-09 13:17:26 +01:00
Yassine Guedidi
66bde5f4c5 Add more precise types 2023-05-02 18:42:48 +02:00
Matthias Pigulla
9c7de27625 Switch back to the original behat/mink-browserkit-driver 2022-11-28 07:50:21 +00:00
Matthias Pigulla
f1971fde57 * Reset also fob_symfony.driver_kernel between scenarios
* Make sure reset() for the Mink driver implementation creates new KernelBrowser instances, to achieve consistent reboots of the `fob_symfony.driver_kernel` when making more than one request within a single scenario
2022-11-26 09:26:34 +00:00
Matthias Pigulla
5ca39f87ff Fix the build pipeline in GitHub Actions 2022-11-24 19:08:50 +01:00
Ruud Kamphuis
237df2e912 Add return type mixed to offsetGet
Turns out that #175 was not enough to make Symfony happy:
```
Method "ArrayAccess::offsetGet()" might add "mixed" as a native return type declaration in the future. Do the same in implementation "FriendsOfBehat\SymfonyExtension\Mink\MinkParameters" now to avoid errors or add an explicit @return annotation to suppress this message.
```
2021-12-14 17:56:03 +01:00
Ruud Kamphuis
8a48661921 Add PHP 8.1 compatibility
Return type of FriendsOfBehat\SymfonyExtension\Mink\MinkParameters::offsetGet($offset) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice
2021-11-13 10:23:18 +01:00
Kamil Kokot
c112c8f25f Merge pull request #123 from ubermuda/feature/use-config-environment-for-app-env 2021-10-20 13:52:16 +02:00
Kamil Kokot
fbcf9d021e Upgrade to Psalm v4.1.1 2020-11-05 21:56:46 +01:00
Kamil Kokot
d597aa3c6c Use imported classname for Client 2020-11-05 21:45:28 +01:00
cv65kr
394c417675 Missing class for Symfony 5 2020-06-18 20:24:36 +02:00
Geoffrey Bachelet
880893206f Fallback to configured environment when no server/env environment is found 2020-04-28 19:01:56 -04:00
Kamil Kokot
0f906e1156 Browser integration 2020-04-04 22:07:00 +02:00
Kamil Kokot
5de4ce6389 Replace PHPStan with Psalm 2020-04-04 20:21:10 +02:00
Kamil Kokot
9609cc1171 Fix a weird bug causing failures in Sylius 2020-04-04 18:26:20 +02:00
Kamil Kokot
13b81e21de feature #116 Accessing tested application services easily via driver's service container (pamil)
This PR was merged into the 2.1-dev branch.

Discussion
----------

Fixes #86, fixes #110.

TODO:
 - [x] Documentation

Commits
-------

776af6cc38 Describe accessing driver's service container
b05304858c Introduce a service in the test application that exposes driver's service container
e94285dc0b Fix coding standard
2020-04-04 15:52:47 +02:00
Kamil Kokot
e94285dc0b Fix coding standard 2020-04-04 15:44:41 +02:00
Kamil Kokot
e37704744c Add safety check for SymfonyDriverFactory to make sure BrowserKitDriver is installed 2020-04-04 15:28:28 +02:00
Kamil Kokot
b05304858c Introduce a service in the test application that exposes driver's service container 2020-04-04 15:26:02 +02:00
Kamil Kokot
019557e8e3 Try to run tests with Behat @ dev-master 2020-01-15 18:54:07 +01:00
Kamil Kokot
f0035b1087 Merge branch '2.0'
* 2.0:
  Generate changelog for v2.0.10
  Fix referencing context initializers
  Add conflict with symfony/stopwatch ^5.0
  Fix the build & add tests for Symfony 4.3 and 4.4
2019-12-09 13:13:33 +01:00
Alexander Kurilo
06104478cc Fix referencing context initializers
With definition, that has been used instead of reference, container has
used to created 2 instances of initializer: one with service id, and one
"anonymous", described by spl_object_hash in a container, it breaked
stateful initializers: in my case initializer was also used to reset
state before next scenario/example, and initializing and resetting happened
with different instances of initializer
2019-12-09 13:01:40 +01:00
Kamil Kokot
15f9801c2b Merge branch '2.0'
* 2.0:
  Change author's website URL
  Do not require base URL set with Mink
  Add base_url to docs for configuring Mink
2019-10-10 17:54:28 +02:00
Kamil Kokot
f3eca984d2 Do not require base URL set with Mink 2019-10-10 17:38:33 +02:00
Kamil Kokot
39a108cded Merge branch '2.0'
* 2.0:
  [HotFix] Force object typehint
  Improve Mink installation docs
2019-09-10 12:25:57 +02:00
Łukasz Chruściel
b056e9b5f0 [HotFix] Force object typehint 2019-09-09 19:52:03 +02:00
Kamil Kokot
ab61dbaa39 Provide simple BrowserKit integration 2019-08-25 18:34:54 +02:00
Kamil Kokot
2f038b27c6 Coding standard fixes 2019-08-25 18:34:16 +02:00
Kamil Kokot
30b6c37537 Fix master build 2019-05-17 17:06:36 +08:00
Kamil Kokot
24a318dc6d Merge branch '2.0'
* 2.0:
  Generate changelog for v2.0.8
  Initialize contexts registered as services
2019-03-21 17:26:59 +01:00
Kamil Kokot
a425be697a Initialize contexts registered as services 2019-03-21 17:16:23 +01:00
Kamil Kokot
cdb51ce570 Merge branch '2.0'
* 2.0:
  Hotfix for weird bug in Sylius
2019-03-17 23:35:18 +01:00
Kamil Kokot
69d150b3dc Hotfix for weird bug in Sylius 2019-03-17 23:29:56 +01:00
Kamil Kokot
0310c16132 Post-upmerge fixes 2019-03-15 15:38:00 +01:00
Kamil Kokot
6170d09b42 Merge branch '2.0'
* 2.0:
  Fix bug preventing changes of Mink default session service
2019-03-15 15:37:04 +01:00
Kamil Kokot
01fe9425a1 Fix bug preventing changes of Mink default session service 2019-03-15 15:21:36 +01:00
Kamil Kokot
8d554a8a32 Merge branch '2.0'
* 2.0:
  Generate changelog for v2.0.4 and v2.0.5
  Allow accessing a context in another context
2019-03-04 14:14:22 +01:00
Kamil Kokot
13d64ca7cb Allow accessing a context in another context 2019-03-04 13:32:16 +01:00
Kamil Kokot
d61600f563 Expose the Mink service 2019-02-13 17:02:21 +01:00
Alan Poulain
8a972b5b48 Apply suggestions from code review
Co-Authored-By: pamil <kamil@kokot.me>
2019-02-13 12:29:55 +01:00
Kamil Kokot
c54c581e74 Refactor our environment handler to decorate the original one 2019-02-13 00:38:07 +01:00
Kamil Kokot
d74cd251d5 Add more sanity checks 2019-02-12 23:42:41 +01:00
Kamil Kokot
cd792704fa Add support for class resolvers 2019-02-12 22:56:42 +01:00
Kamil Kokot
717c869ad6 Revert mink parameters autoconfiguration 2019-02-07 11:58:17 +01:00
Kamil Kokot
394b9abdfc Fix support for context initializers 2019-01-30 17:10:20 +01:00