Benedikt Heine
c37326c9a0
Move memory allocation into test methods
...
This implies, that memory will only get freed, if the whole test method
is gone through. In case of failure, memory leaks aren't important. But
it's crucial not to fail with a segfault just for an assertion.
Fixes #580
2019-01-03 12:21:05 +01:00
Benedikt Heine
84e5a0bf26
Make notification_is_duplicate test icons
...
Before, it only did test for `ASSERT_FALSE` both times. So a raw_image
wasn't guaranteed to be a condition to falsify the return.
Using the single field function, will test for both cases.
2019-01-03 12:19:53 +01:00
Benedikt Heine
c1090ad7dc
Merge pull request #568 from bebehei/dbus-test
...
Dbus test
2018-12-31 05:58:14 +01:00
Benedikt Heine
330faa3e5a
Add ability to test ActionInvoked signal
2018-12-30 17:07:27 +01:00
Benedikt Heine
a66ef34546
Do not use clang for coverage
...
When using clang, this will create a race condition between
clang/gcc builds. Coveralls will take the first one. As GCC and clang
are counting line coverage differently, coveralls regularly fails.
2018-12-30 17:07:04 +01:00
Benedikt Heine
c236ef7751
Always use an odd number of actions during testing
2018-12-30 17:07:04 +01:00
Benedikt Heine
62a83e183e
Test urgency hints in DBus
2018-12-30 17:07:04 +01:00
Benedikt Heine
3c5b15d630
Test category hint in DBus
2018-12-30 17:07:04 +01:00
Benedikt Heine
416da59e9e
Test icon hints in DBus
2018-12-30 17:07:04 +01:00
Benedikt Heine
01784d5514
Test progress hints in DBus
2018-12-30 17:07:04 +01:00
Benedikt Heine
5e616516df
Test transient hints in DBus
2018-12-30 17:07:01 +01:00
Benedikt Heine
5ebedab78b
Fix maybe uninitialized variable
2018-12-29 14:38:59 +01:00
Benedikt Heine
63f455276f
Print correct ID for foreign DBus service
...
By providing an additional layer of pointers, the printed PID was
actually the value at the PID's memory position. 🙈
2018-12-29 14:38:59 +01:00
Benedikt Heine
57a6baae85
Test FDN Daemon info
2018-12-29 14:38:59 +01:00
Benedikt Heine
fb483347ed
Test close signals
2018-12-29 14:38:59 +01:00
Benedikt Heine
ae58207f9b
Use binary search for functions
2018-12-29 14:38:58 +01:00
Benedikt Heine
c35801b3ab
Use a macro for method callbacks
2018-12-29 14:36:50 +01:00
Benedikt Heine
4fbb8fa75b
Prefix dbus callbacks with dbus_cb_
2018-12-29 14:31:31 +01:00
Benedikt Heine
0d82b19987
Add test for empty notification
2018-12-29 14:31:31 +01:00
Benedikt Heine
caffb0b10c
Add tests for notification color hints
2018-12-29 14:31:31 +01:00
Benedikt Heine
b10bb292c6
Simplify DBus notification assembly
2018-12-29 14:31:31 +01:00
Benedikt Heine
a8faea725d
wait longer for DBus in tests
...
While running under valgrind, it may take over 30 cycles in the loop to
wait for a running GTestDBus instance. So we have to increase the
waiting time.
Waiting a whole second will change the signal/noise ratio and will only
fail, if there's really a problem with the GTestDBus usage.
And as we're sleeping 500us in every loop, we usually get a super fast
response, too.
2018-12-29 14:31:31 +01:00
Benedikt Heine
314d982bf4
Add capability tests for DBus
2018-12-29 14:31:31 +01:00
Benedikt Heine
3598aaf3e2
Add initial dbus tests
2018-12-29 14:31:29 +01:00
Benedikt Heine
52885ca6ad
Use a hashtable for notification actions
...
As g_strv_contains is only available in GLib >= 2.44, we have to bump
the GLib requirements and the CI distros, too.
2018-12-29 14:30:55 +01:00
Benedikt Heine
a359b74901
Merge pull request #555 from anbenson/master
...
Add tests for extract_urls
2018-12-29 13:54:09 +01:00
Benedikt Heine
f4b8fff89d
Simplify pointer test cases
2018-12-29 13:50:35 +01:00
Benedikt Heine
d40b42c77d
Add additional tests for extract_urls
2018-12-27 20:59:48 +01:00
Benedikt Heine
db350883cc
Improve extract_urls
2018-12-27 20:59:47 +01:00
Andrew Benson
65bcce652c
Add tests for extract_urls
2018-12-27 20:59:19 +01:00
Benedikt Heine
c562c6441a
Add CircleCI status badge
2018-12-10 04:21:46 +01:00
Benedikt Heine
ab56b47d97
Use official CI docker images
2018-12-10 04:19:25 +01:00
Nikos Tsipinakis
fd486d06d5
Merge pull request #567 from bebehei/circleci
...
CircleCI
2018-12-02 15:37:59 +02:00
Benedikt Heine
90813dde8e
Update Fedora version to latest
2018-11-29 10:29:22 +02:00
Benedikt Heine
91adaa0da9
Use clang and GCC simultaneously
2018-11-28 21:22:36 +02:00
Benedikt Heine
3c28432044
Do not use -j for clean
...
-j introduces race conditions, which lets the find -name ... -delete
commands fail, because those can't find specific files, which got
removed in the meantime.
2018-11-28 21:22:36 +02:00
Benedikt Heine
394393fb6e
Let's test CircleCI
2018-11-28 21:22:36 +02:00
Nikos Tsipinakis
0a2802af75
Merge pull request #566 from bebehei/notification-colors
...
Notification colors
2018-11-27 14:36:02 +02:00
Benedikt Heine
ecfe64c4bd
Cleanup unused macros
2018-11-26 19:54:21 +01:00
Benedikt Heine
7e81506226
Remove colors field from xctx
...
The xctx color field is a full duplicate of the settings logic.
Only logic included in xctx color fields, are the frame colors, which
fall back to the global frame setting. So, this required to handle it
directly in settings.c
2018-11-26 19:54:07 +01:00
Benedikt Heine
3e205ff159
Use notification_colors struct in settings
2018-11-26 18:17:00 +01:00
Benedikt Heine
c3cd623f41
Use notification_colors struct for notification colors
2018-11-26 17:31:46 +01:00
Nikos Tsipinakis
f02a0d4b8d
Merge pull request #561 from tsipinakis/bugfix/drop-libdbus
...
Drop libdbus dependency
2018-11-26 17:03:46 +02:00
Nikos Tsipinakis
baf0ec3e11
Remove dbus build flags
...
We haven't been using libdbus for a while so there is no use to
linking it with the build.
Unfortunately there is still a dependency on it as we depend on the dbus
package to tell us where to put our service files.
2018-11-26 16:05:50 +02:00
Benedikt Heine
7b1157c5af
Merge pull request #564 from bebehei/testsuite
...
Misc Testsuite updates
2018-11-26 15:00:45 +01:00
Benedikt Heine
b9b803d0ea
The memory leaks should be fixed by librsvg
2018-11-26 12:57:37 +01:00
Benedikt Heine
5284ce01f4
Make notification tests easier
2018-11-26 12:19:17 +01:00
Benedikt Heine
193b1f7202
Test notification maximum length
2018-11-26 12:19:17 +01:00
Benedikt Heine
1b4ca786cd
Test notification_format_message
2018-11-26 12:17:50 +01:00
Benedikt Heine
6988a6e04d
Add tests for log.c
2018-11-26 12:08:18 +01:00