69 Commits

Author SHA1 Message Date
40fec3c530
Fix the default firewall in test login
Update admin client authentication method

Modified `getClientAuthenticatedAsAdmin` to accept an optional firewall parameter and updated dependency to use `chill_in_memory` user provider. This allows more flexible and configurable testing of client authentication against different firewalls.
2024-11-22 09:45:07 +01:00
f0f651edea
update cs after php-cs-fixer upgrade 2024-09-12 12:02:33 +02:00
916724c0c5
Merge branch 'master' into upgrade-sf5 2024-06-24 10:46:21 +02:00
6bd38f1a58
Refactor assertions in AbstractAggregatorTest
The conditional checks in the AbstractAggregatorTest have been simplified. Instead of a complex inline condition with multiple checks, the test now uses straightforward assertions. This makes the code cleaner and easier to understand.
2024-06-17 15:31:33 +02:00
0081146a78
Change non-static class-level variables and methods to static in tests's data providers
The update modifies several test classes within the "chill-project" to change non-static class-level variables and methods to static ones. This change has been made to improve readability, performance, and to eliminate unnecessary instantiation of class objects in test scenarios. Also, flush and clear actions on the entity manager are moved to individual data providers.
2024-02-19 15:38:28 +01:00
07f03ab715
Make data providers static on AbstractExportTest.php and Write a rector rule to adapt existing 2024-02-16 21:49:27 +01:00
11f6b78b26
Make static some methods in AbstractAggregatorTest.php + rector rule to adapt existing 2024-02-16 19:16:07 +01:00
fa0204adbc
Refactor test methods in AbstractFilterTest to be static + rector rules for updating existing
All test methods in AbstractFilterTest class have been refactored to be static.

A rector rule has been created to refactor existing test.
2024-02-14 22:30:16 +01:00
f889d67e94
fixes after merge of master into upgrade-sf4 2024-02-12 22:31:16 +01:00
37af488f69
Merge branch 'master' into upgrade-sf5 2024-02-12 21:50:34 +01:00
2ed42e1a2c
Fix cs with php-cs-fier version 3.49 2024-02-08 21:12:27 +01:00
e902b6d409
Create a page which list events 2024-02-08 12:59:50 +01:00
cef218fed5
Add interface for pagination 2024-02-08 12:59:47 +01:00
1098bafd3d
Replaced the deprecated 'self::$container->get' with 'self::getContainer()->get' using rector
This change is made to comply with the new Symfony standards and to avoid deprecation warnings for future versions. The update touches various functionalities, including retrieving EntityManagerInterface instance and various service classes within the test files.
2023-12-14 23:36:56 +01:00
7ba3435c41
Refactor PrepareClientTrait to use the loginUser method 2023-12-14 22:56:50 +01:00
a6e930958b
[export] create a parameter that will force to skip the filtering by center (ACL) when generating an export 2023-10-19 17:19:28 +02:00
bc2041cbdd
apply more cs rules for php-cs 2023-10-17 13:27:03 +02:00
e3559774fd
Improve the signature definition 2023-10-03 21:25:22 +02:00
d3b68f8f8f
AuthorizationHelper: compare center and scope based on id, not on equality
For an unknown reason, in some circumstances, the use of the `===` comparator does not work when comparing Center instances and Scope instances. Then, we compare them based on the id.
2023-09-13 10:08:44 +02:00
40b7c8ad8f
fix rector and cs 2023-09-01 17:50:07 +02:00
0db1e3e0d7
Exclude db intensive test to spare db connection 2023-09-01 17:17:17 +02:00
a2a660c954
Try to avoid open db connections 2023-09-01 17:07:10 +02:00
2c52a5bffa
Fix tests 2023-09-01 16:10:04 +02:00
10a75f44e9
Ensure kernel shutdown after abstract export tests 2023-09-01 16:09:54 +02:00
37c1dfb0ba
fix tests implementing AbstractAggregatorTest 2023-09-01 15:07:37 +02:00
a197a6b418
fix tests implementing AbstractFilterTest 2023-09-01 14:21:03 +02:00
355ed03500
Fix kernel booting problem on Aggregator and Filter tests 2023-09-01 11:08:15 +02:00
b85cd1b994
DX: apply rector rules for phpunit up to 90 2023-08-31 11:08:42 +02:00
f570fe92a5
apply rector rules 2023-07-28 02:40:02 +02:00
0e94e769cb
Remove reference to deprecated Role class in tests 2023-07-28 01:16:53 +02:00
5f6e506300
Fix: AuthorizationHelperTest: remove deprecated and deprecation of PrepareScopeTrait 2023-07-27 23:51:57 +02:00
dde3002100
DX: apply rector rules up to php8.0 2023-04-28 22:30:33 +02:00
b9a7530f7a
DX: apply rector rulesset up to PHP72 2023-03-29 22:32:52 +02:00
2f77deaa60 fix cs 2022-10-10 20:53:49 +02:00
5acf7a81d7 DX: deprecated ProphecyTrait in favour of the one coming from Prophecy\PhpUnit package. 2022-10-10 20:52:35 +02:00
629e4ab02d Merge branch 'atelier_tests' into '111_exports_suite'
Add tests which check that an alias do not disappears in filters / aggregators

See merge request Chill-Projet/chill-bundles!455
2022-10-10 10:41:41 +00:00
9699e2304a fix cs: declare type and license header mismatch 2022-10-06 22:25:43 +02:00
b394d7247d fix cs: too much line before declaring strict type 2022-10-06 08:55:32 +02:00
67c3f3a840 fix cs with licencse header 2022-10-05 17:08:14 +02:00
a967e1ed17 fix cs 2022-10-05 15:23:28 +02:00
ccedebda90 Add new Abstract Filter Test to check qb aliases (for join clauses) 2022-09-29 20:48:56 +02:00
eb6efcefd8 Add new Abstract Aggregator Test to check qb aliases (for join clauses) 2022-09-29 20:48:56 +02:00
3c8dbe56fc exports: create new aggregator tests + minor corrections in aggregators 2022-09-21 14:31:46 +02:00
27306015f4 exports: create new filter tests 2022-09-21 11:29:08 +02:00
211a80e9be deprecate chill prophecy train in favor of prophecy-phpunit bridge 2022-09-17 08:23:28 +02:00
e3743d3593 tests new filters ReferrerFilter and OpenBetweenDatesFilter (wip.. test failed) 2022-08-04 09:07:45 +02:00
b9186ed6e0 tests: write a simple Export test for new indicators + fix depreciation with BrowserKit client
cfr: https://symfony.com/doc/4.4/components/browser_kit.html#creating-a-client
2022-07-27 18:39:58 +02:00
8bbca12487 fix ProphecyTrait in AbstractFilter to use it with each filter 2022-07-27 14:23:21 +02:00
3dabd031f4 fix tests failed in exports 2022-07-27 14:23:21 +02:00
864e1eeabb replace more doctrine shortcuts by fqdn 2022-04-30 00:35:11 +02:00