mirror of https://github.com/FriendsOfTYPO3/tea.git synced 2024-11-24 12:36:13 +01:00
Commit graph

52 commits

Author SHA1 Message Date
Oliver Klee
b2d2f2a705
[TASK] Ensure a type in a test (#1268) 2024-05-06 11:18:22 +00:00
Oliver Klee
248c759206
[TASK][!!!] Require a storage PID for the tea list (#1223)
Fixes #1024
Supersedes #1024
2024-04-15 11:13:57 +02:00
Oliver Klee
188ca41922
[TASK] Reduce the DB fixtures some more (#1226)
Do not provide the PID where the PID is not relevant to the test.

This allows the reader to see more easily what is relevant for the
test.

Also reduce unnecessary quoting of integers in the DB fixtures.
2024-04-15 07:57:18 +02:00
Oliver Klee
e9019ddae8
[TASK] Test that TeaRepository.findByOwnerUid ignores the storage PID (#1227) 2024-04-15 07:21:27 +02:00
Oliver Klee
fe79124c0e
[TASK] Rework a test communicate its purpose more clearly (#1133)
When the ordering of items (by title) is verified, checking the
title instead of the UID makes this more clear.

Fixes #1132
2024-01-24 07:38:51 +01:00
Oliver Klee
eeda862e77
[!!!][TASK] Drop additional namespace segment for the Tea model (#1025)
The `Product` namespace segment in the domain model namespace
`TTN\Tea\Domain\Model` currently serves no purpose and only adds
confusion. So let's simplify the extension structure accordingly.

(I intended to use this to demonstrate DDD contexts, but never
built enough models in the Tea extension for this to actually
make sense.)

Fixes #1008
2024-01-16 15:21:21 +01:00
58971754c4
[TASK] Add missing test case for fetching none existing tea (#1017)
Dedicated test cases were added in the past.
This test case was not added yet.

Resolves: #858
2023-11-27 12:36:42 +00:00
d56d58ed04
[CLEANUP] Migrate typo3conf path to composer package name (#1012)
The tests now respect the TYPO3 extension key as well as the composer
package name.
There is no more need to use the old (no longer used) typo3conf/ext
path.

Resolves: #739
2023-11-27 12:10:13 +01:00
Oliver Klee
d9718fd054
[TASK] Split up the DB fixtures for the functional tests (#993)
This makes the fixture more minimal and reduces cross-dependencies
between tests.

Also consistently avoid quotes for integer data in CSV DB fixtures.

Fixes #988
2023-11-19 22:36:32 +01:00
Oliver Klee
d15bd079d6
[TASK] Migrate DB queries to CSV assertions in the functional tests (#998)
This makes the corresponding test a lot more concise and easier to
read.
2023-11-19 22:34:02 +01:00
Oliver Klee
3cdf8df7a0
[CLEANUP] Inline some variables in the tests (#997)
This makes the tests more concise while still keeping them readable.
2023-11-18 06:44:40 +01:00
Oliver Klee
3d92e0cc98
[CLEANUP] Use power of the DI container in the functional tests (#961) 2023-11-01 20:24:26 +01:00
Oliver Klee
bbe469169b
[FEATURE] Add Tea.ownerUid (#860)
This is a pre-patch for adding a CRUD plugin for tea records.

This property contains only the UID of the owner FE user, but not
a relation to a FE user model. This is because we neither have nor
need a FE user model for the purposes of the CRUD plugin.
2023-06-21 09:16:13 +02:00
Oliver Klee
77057e06a8
[TASK] Make the repository tests more fine-grained (#855)
Tests should only test one thing (if possible).
2023-06-20 09:10:31 +02:00
68372cc850
[TASK] Make all test cases final (#801)
Resolves: #797
2023-04-06 14:34:15 +00:00
Łukasz Uznański
7cd09a3b52
Upgrade to TYPO3 v12.2 (#746) 2023-02-08 17:26:08 +01:00
Oliver Klee
a6c4a86273
[BUGFIX] Get the functional tests to work with TYPO3 >= 12.1 (#704)
Starting with TYPO3 12.1, a request is required for the
`BackendConfigurationManager` to not crash:
https://review.typo3.org/c/Packages/TYPO3.CMS/+/76447

Also, a fix in that area has been merged (after the release of TYPO3 12.1)
that might allow us to remove our workaround again once we've updated to
TYPO3 12.2 or 12.1.3:
https://review.typo3.org/c/Packages/TYPO3.CMS/+/77028
2022-12-22 09:47:55 +01:00
Oliver Klee
1e157e6958
[TASK] Upgrade to the testing framework V7 (#629)
* [TASK] Upgrade to the testing framework V7

This is required to also run the tests on TYPO3 12LTS.

* Update CHANGELOG.md

Co-authored-by: Lina Wolf <48202465+linawolf@users.noreply.github.com>
Co-authored-by: Chris Müller <2566282+brotkrueml@users.noreply.github.com>
2022-10-13 13:52:25 +02:00
Oliver Klee
0a1a00dd22
[CLEANUP] Drop usages of ObjectManager whereever possible (#616)
Fixes #596
2022-10-10 02:15:33 +02:00
Oliver Klee
4537d5fca9
[CLEANUP] Drop some redundant PHPDoc type annotations (#611) 2022-10-06 17:51:04 +02:00
Lina Wolf
8be6d02315
[TASK] Convert functional test fixtures to CSV (#601)
Fixes #600

Co-authored-by: lina.wolf <lwolf@w-commerce.de>
2022-10-03 19:10:08 +02:00
Lina Wolf
e469041db7
[CLEANUP] Use typed properties instead of @var annotations (#599)
The `@var` annotations where left where it is not possible yet to replace them in PHP 7.4.

Fixes #550

Co-authored-by: lina.wolf <lwolf@w-commerce.de>
2022-10-03 19:00:55 +02:00
Oliver Klee
dc6c0eedeb
[TASK] Change misleading variable names in some tests (#470)
We are not using any "container" class here, and hence the results from
repository find methods should be named `$result` instead of `$container`.
2022-06-28 23:52:02 +02:00
Oliver Klee
569fad3626
[CLEANUP] Remove type annotations for fields from the testing framework (#453)
As in these cases the type annotations from the base class are used,
we can avoid PHPStan warnings about discrepancies between our annotations
and the annotations from the testing framework for the corresponding
fields in the superclass.
2022-06-01 15:26:47 +02:00
Oliver Klee
71a08a1c20
[BUGFIX] Mark the repository test as also covering the model (#436)
We currently can only test the lazy loading of the model image
with a functional test that retrieves a model from the database
via the repository.

So the functional test for the repository also needs to be marked as
covering the model class to make our code coverage correct.
2022-04-29 14:54:41 +02:00
Oliver Klee
f1a0fbef04
[CLEANUP] Use prepared statements for SQL queries in the tests (#443)
Also add another type check to help with debugging failed queries.
2022-04-29 14:27:47 +02:00
Mathias Bolt Lesniak
3ca00b78e4
[BUGFIX] Use executeQuery() in functional test example (#422)
This avoids potential false results in the tests because it doesn't add additional restrictions for starttime, endtime, deleted, and hidden.

Fixes #421
2022-04-11 14:15:43 +02:00
Oliver Klee
869f348ce8
[CLEANUP] Make a type annotation more specific (#415) 2022-03-30 12:14:04 +02:00
Oliver Klee
a1a84a511f
[BUGFIX] Configure DI and avoid using ObjectManager in TYPO3 11LTS (#399)
`ObjectManager` is deprecated in V11.

Fixes #387
2022-03-02 02:07:25 +01:00
Oliver Klee
4f2c813d7f
[TASK] Switch to the core testing framework (#361)
The TYPO3 core testing framework has more person-power for maintenance
behind it compared to the nimut testing framework. So we should use that.
2022-02-20 15:18:46 +01:00
Łukasz Uznański
f0127b3b64
[TASK] Fix php cs related to official configuration (#341)
Co-authored-by: Łukasz Uznański <l.uznanski@macopedia.com>
2021-11-17 13:14:43 +01:00
Oliver Klee
ca9a8e4e15
[TASK] Always use @covers annotations in the tests (#298) 2021-09-15 02:11:15 +02:00
Łukasz Uznański
4bde411dd8
[TASK] Remove author annotations (#294)
Co-authored-by: Łukasz Uznański <l.uznanski@macopedia.com>
2021-09-07 08:51:11 +02:00
Andreas Wolf
3f3c9285d9 [CLEANUP] Fix PHP_Codesniffer issues
Resolves: #21
2019-12-07 12:13:32 +01:00
Oliver Klee
29bf7ccae5
[TASK] Convert the PHP namespaces to "TTN" (#9)
Fixes #1
2019-12-01 12:16:06 +01:00
Oliver Klee
b519583431
[CLEANUP] Fix code inspection warnings (#57) 2019-08-12 17:43:02 +02:00
Oliver Klee
3401e32a84
[FEATURE] Add PHP-CS-Fixer (#53)
Also run the fixer on all classes and tests.
2019-08-12 17:25:59 +02:00
Oliver Klee
3e4d10cc12
[FEATURE] Add tests using the database abstraction (#25) 2018-05-28 15:17:19 +02:00
Oliver Klee
09dc1281ca
[FEATURE] Add Tea.image as a FAL example (#15) 2018-05-25 22:39:33 +02:00
Oliver Klee
9b10334c0d
[FEATURE] Add default sorting by title to the TeaRepository (#14) 2018-05-25 17:38:51 +02:00
Oliver Klee
e2f39033c0
[FEATURE] Tea model and repository (#10) 2018-05-25 16:19:12 +02:00
Oliver Klee
bbb6f8e5f0
[TASK] Add the default directory structure (#7)
Also use spaces for indentation in the .htaccess files.
2018-01-27 15:54:51 +01:00
Oliver Klee
4b7ffe0546 [CLEANUP] Empty out the extensions 2017-12-22 22:20:43 +01:00
Oliver Klee
563f4befbf [CLEANUP] Use strict types, scalar type hinting and return types 2017-09-08 18:04:28 +02:00
Oliver Klee
3cc3fd09b1 [TASK] Switch the functional tests to nimut/testing-framework 2017-09-08 16:09:51 +02:00
Oliver Klee
bc58abde55 [TASK] Make the extension compatible with TYPO3 CMS 7.6 2016-07-16 21:39:04 +02:00
Oliver Klee
31b1044fb5 [CLEANUP] Rework tests to match the TDD examples 2016-05-08 14:57:07 +02:00
Oliver Klee
d0871fb5f8 [CLEANUP] Use the short array syntax 2016-05-07 21:56:27 +02:00
Oliver Klee
b6bb92d0da [CLEANUP] Reformat the code as PSR-2 2016-05-07 21:43:25 +02:00
Oliver Klee
a4721b0d1c [FEATURE] Add a DBUnit example
This is the functional test for the TeaBeverageRepository.
2015-10-26 23:37:57 +01:00