Page MenuHomePhorge

Run kolab tests in CI
ClosedPublic

Authored by mollekopf on Jul 12 2022, 4:47 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Mar 21, 5:55 PM
Unknown Object (File)
Mon, Mar 18, 8:54 AM
Unknown Object (File)
Tue, Mar 12, 10:41 AM
Unknown Object (File)
Tue, Mar 5, 3:07 PM
Unknown Object (File)
Feb 19 2024, 7:38 PM
Unknown Object (File)
Feb 19 2024, 5:01 AM
Unknown Object (File)
Feb 15 2024, 9:34 AM
Unknown Object (File)
Feb 14 2024, 12:53 AM
Subscribers

Details

Summary

This allows us to run kolab4 tests in CI (tested on centos8).

The test is executed via ci/Makefile (all target)

Some of the changes include:

  • Configurable ssl certificate
  • Do not persist the node modules
  • swoole needs to be built before the rest
  • Install kolab from the new mirror
  • Buildkit seems to be the reason for the centos7 problems
  • Various test fixes, and skip tests that don't currently pass
  • docker-compose is now a plugin

Diff Detail

Repository
rK kolab
Branch
dev/ci
Lint
Lint Errors
SeverityLocationCodeMessage
Errorsrc/tests/Browser/ErrorTest.php:22PHP1Parse Error
Errorsrc/tests/Browser/ErrorTest.php:22phpstanSyntax error, unexpected T_OBJECT_OPERATOR on line 22
Unit
No Test Coverage
Build Status
Buildable 39464
Build 16070: arc lint + arc unit

Event Timeline

mollekopf created this revision.
mollekopf edited the summary of this revision. (Show Details)

Rebased on master

mollekopf added a reviewer: Restricted Project.Jul 12 2022, 4:50 PM
machniak subscribed.
machniak added inline comments.
docker/tests/lint.sh
17

We also have npm run lint for js/css.

src/tests/Browser/ErrorTest.php
22

I'm sure this will fail for me. These two lines of code should be replaced with ->assertErrorPage(404), it does the same in a case-insensitive way.

29–30

Same as above.

src/tests/Feature/Backends/IMAPTest.php
20 ↗(On Diff #10589)

If it fails here, then maybe we need to wait before we start testing, I assume the IMAP is not yet ready with the seeded mailboxes.

src/tests/Feature/Console/User/StatusTest.php
33 ↗(On Diff #10589)

Is kolab4 worker working? It is responsible for creating ldap/imap entries and verification. Or maybe it needs more time? Some tests assume all jobs created while seeding database have been processed.

This revision now requires changes to proceed.Jul 13 2022, 8:16 AM
mollekopf marked 2 inline comments as done.
mollekopf edited the summary of this revision. (Show Details)

Addressed comments and fixed a lint failure in the mollie controller.

I removed skipci from the previously failing imap tests. I can't reprodcuce at the moment so it's probably a race condition that I'll look into once I can reproduce.

mollekopf retitled this revision from docker-compose is now a plugin to Run kolab tests in CI.Aug 2 2022, 2:08 PM
mollekopf edited the summary of this revision. (Show Details)

Two comments, looks good otherwise.

src/.env.example
178

I'm not sure about storing more options like these in the same file. We have already some other options that aren't used by Kolab4 code. A separate file would be better, but we can handle that separately, I guess.

src/app/Providers/Payment/Mollie.php
345

In fact we should probably try/catch instead to do what Mollie recommends and return 200.

This revision is now accepted and ready to land.Aug 2 2022, 2:54 PM
This revision was automatically updated to reflect the committed changes.
src/.env.example
178

I agree this is becoming a concern, there's a relatively wild mix of options for kolab4 and docker-compose.

src/app/Providers/Payment/Mollie.php
345

I created a diff for it.