This commit squashes several non-compiling commits: 66dd6500 Change required GMime version to 3.2.4 or higher 4b9c8a38 Fix some compilations errors in test code 98aa5a2e Fix some (hopefully) last compilation errors 558360c6 Fix parser format when getting message headers cc248ffc Fix name of stream-buffer mode b293c66b Fix another iteration over a header-list 52fa183f Fix parsing of Gmime parameters e078ee62 Use Unix2Dos-, Dos2Unix- and/or SmtpData-filters instead of 'FilterCRLF' ff31b8e5 Fix setting of email headers eb676482 Fix compilation errros due to string-uint8-char conversion problems 8558769f Fix datetime conversion d44a28cd Remove some obsolete arguments 1ce81662 Pass charset where it's required 6013806f Pass GMime.ParserOptions to header-decode methods 986d05a0 Pass GMime.FormatOptions where it's required e9b93187 Pass GMime.ParserOptions where it's required 640ce667 Fix compilation errors in GMime initialization 312f80bf Remove use of GMime.HeaderIter acc73d14 Change GMime dependency from 2.6 to 3.0 54fc250a Adapt names to 'offical' gmime-2.6 bindings The commits are part of the branch 'letorbi/gmime-3-spread', which can be found at: https://gitlab.gnome.org/letorbi/geary/tree/letorbi/gmime-3-spread |
||
|---|---|---|
| .. | ||
| client | ||
| data | ||
| engine | ||
| integration | ||
| js | ||
| meson.build | ||
| mock-object.vala | ||
| README.md | ||
| test-case.vala | ||
| test-client.vala | ||
| test-engine.vala | ||
| test-integration.vala | ||
Automated Test Infrastructure
Geary currently supports three types of automated tests:
- Engine unit tests
- Client (GTK and JavaScript) unit tests
- Server integration tests
Unit tests
Unit tests test individual functions, in general avoid doing any I/O so they are fast, and can be run automatically.
The engine and client unit tests are hooked up to the Meson build, so you can use Meson's test infrastructure to build and run them. These are run automatically as part of the Gitlab CI process and if you use the development Makefile, you can execute them locally by simply calling:
make test
The engine tests can be run headless (i.e. without an X11 or Wayland session), but the client tests require a functioning display since they execute GTK code.
Integration tests
Integration tests run Geary's network code against actual servers, to ensure that the code also works in the real world.
The integration tests are built by default, but not currently hooked up to Meson and are not automatically run by Gitlab CI, since they require multiple working servers, network connection to the servers, and login credentials.
You can run them manually however against any server you have a test account on, using the following form:
build/test/test-integration PROTOCOL PROVIDER [HOSTNAME] LOGIN PASSWORD
For example, to test against GMail's IMAP service:
build/test/test-integration imap gmail test@gmail.com p455w04d
If PROVIDER is other, then HOSTNAME is required.
The easiest way to test against a number of different servers at the moment is to create a test account for each, then write a shell script or similar to execute the tests against each in turn.