Franz Liedke
23ad5bcc6b
Integration tests: Add lazy server helper
...
This allows sending requests directly in an integration test, without
having *explicitly* booted the app.
2021-01-13 01:21:38 -05:00
Franz Liedke
1ca610d96a
Integration tests: Create app lazily when needed
...
This will allow registering extenders in test scenarios. Previously,
this would not have had any effect as the app would have booted already.
2021-01-13 01:21:38 -05:00
Matt Kilgore
924a2e5efa
Change Zend namespace to Laminas ( #1963 )
...
Also ensure backwards compatibility for extensions that use the Zend framework but don't explicitly require it.
2021-01-13 01:21:38 -05:00
Franz Liedke
48d996d948
Apply fixes from StyleCI
...
[ci skip] [skip ci]
2021-01-13 01:21:38 -05:00
Daniël Klabbers
c772029af9
Apply fixes from StyleCI ( #1800 )
...
[ci skip] [skip ci]
2021-01-13 01:21:38 -05:00
Daniël Klabbers
f47d739aac
Using a different setting key now, so that it won't break tests whenever you re-run them once smtp is set.
...
Fixed, badly, the test to create users etc caused by the prepareDatabase flushing all settings by default.
2021-01-13 01:21:38 -05:00
Franz Liedke
c5d042929f
Refactor tests to shorten HTTP requests
...
Multiple tests now provide JSON request bodies, and others copy cookies
from previous responses, so let's provide convenient helpers for these.
2021-01-13 01:21:38 -05:00
Franz Liedke
05b4d8076b
Integration tests: Configure vendor path
...
Now that this is possible, make the easy change...
2021-01-13 01:21:38 -05:00
Franz Liedke
e6d4c66933
Integration tests: Memoize request handler as well
...
This is useful to send HTTP requests (or their PSR-7 equivalents)
through the entire application's middleware stack (instead of
talking to specific controllers, which should be considered
implementation detail).
2021-01-13 01:21:38 -05:00
Toby Zerner
0b657c0b4c
Restore Initial Meaningful Test Infrastructure
...
This testing package was initially a part of flarum/core, but was
extracted during the 0.1.0-beta.16 release cycle. The extraction was
made through git's filter-branch tool to preserve some useful history in
the repository.
2021-01-13 01:21:33 -05:00