Commit Graph

21 Commits

Author SHA1 Message Date
Daniel Hahler dc98eade3b
naughty: fix extra newline with only title/message (#2870)
* tests/test-naughty-legacy.lua: s/counter/added_counter

* naughty: fix extra newline with only title/message

With only title or message it should not have an extra newline.

Fixes: https://github.com/awesomeWM/awesome/commit/423aeebe8#commitcomment-35062951
2019-09-19 02:11:18 +02:00
Daniel Hahler 0cbf536269
test-naughty-legacy.lua: harden/cleanup (#2873) 2019-09-13 16:00:51 +02:00
Emmanuel Lepage Vallee 6d58d7b4a2 tests: Test that the legacy naughty popup is used when the new API fails
Displaying errors is important. If the notification popup caused the
error, it was likely nothing could be displayed.
2019-08-03 01:45:22 -04:00
Emmanuel Lepage Vallee 529f4be53e tests: Check that naughty emits "request::display_error" when needed. 2019-08-03 01:45:22 -04:00
Emmanuel Lepage Vallee aed2af44b6 tests: Check if using client icon doesn't exceed the size constraints. 2019-08-03 01:45:22 -04:00
Emmanuel Lepage Vallee 6761778830 tests: Test the notification icon theme request::icon support. 2019-08-03 01:45:22 -04:00
Emmanuel Lepage Vallee 4fe05a566d tests: Test exposing the notification persistence and animation props 2019-08-03 01:45:22 -04:00
Emmanuel Lepage Vallee 7d609fb69b tests: Test the notification spec v1.2 "resident notification" support.
If a notification is resident, invoking an action should not destroy it.
If an action is not resident, invoking an action destroys it.
2019-08-03 01:45:22 -04:00
Michael Beaumont 9e2a544ba3 naughty: Add position "middle" to center notifications in screen (#2775)
Signed-off-by: Michael Beaumont <mjboamail@gmail.com>
2019-06-08 16:10:14 -04:00
Emmanuel Lepage Vallee 0b820b077d tests: Fix the tests then notify-send is not installed.
Fix #2684
2019-03-03 16:24:17 -05:00
Emmanuel Lepage Vallee 4930978424 naighty: Fix to use the same object using `naugthy.notify{replace_id}`
Fix #2678
2019-03-03 16:24:17 -05:00
Emmanuel Lepage Vallee 9954e43521 tests: Use the same string for both notification lines.
Otherwise you cannot compare the width since `r` is thinner than `z`
in some non-monospace fonts.
2019-03-02 12:51:03 -05:00
Emmanuel Lepage Vallée f049046332
Merge pull request #2696 from alfunx/naughty-legacy-resize-on-update
naughty: Resize notification when setting text
2019-02-24 15:12:35 -05:00
Alphonse Mariya 04c9477f73
test: Test notification resizing on text change 2019-02-24 19:46:25 +01:00
Emmanuel Lepage Vallee e9d44e820d test: Test the notification ids 2019-02-24 12:08:50 -05:00
Emmanuel Lepage Vallee ecec00f425 tests: Disable a test that's invalid 2019-02-22 11:47:46 -05:00
Uli Schlachter 828ce1471e test-naughty-legacy: Use GDBus instead of spawning dbus-send
This is inspired to be a correctness fix: The "hints" argument to
notifications is supposed to have type a{sv}, i.e. this maps from string
keys to some generic value. dbus-send does not support this and instead
it sends an argument of type a{ss}, i.e. a mapping from string to
string. This commit fixes this problem and uses the correct type.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2019-02-19 18:35:09 +01:00
Uli Schlachter a54eb67de0 naughty test: Use array-style spawn() calls
When a string is spawned, the C code has to split this into an array for
the execve() syscall. When an array is given directly, this array does
not need to be transformed in any way. This makes it much more clear
what is actually started.

This commit removes some quotation marks that were previously removed by
the C code. For example,

    array:string:1,"four",2,"five",3,"six"

became

    array:string:1,four,2,five,3,six

because otherwise the action was called "four" instead of four and the
test failed.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2019-02-17 10:30:31 +01:00
Uli Schlachter 083462e0c1 naughty test: Warn about missing dependencies
Signed-off-by: Uli Schlachter <psychon@znc.in>
2019-02-17 10:21:18 +01:00
Emmanuel Lepage Vallee 1b4c1e9f1c tests: Test the naughty deprecated APIs 2019-02-16 15:49:39 -05:00
Emmanuel Lepage Vallee db591b50a4 tests: Add extensive tests for the existing notification features.
This new test suit add a rather extensive coverage to the "legacy"
notification popups. A few minor bugs have been found and fixed
and we can rest assured that the new spec 1.2 support and extended
manipulation API wont regress existing configs.
2019-02-16 15:49:39 -05:00