Commit Graph

13 Commits

Author SHA1 Message Date
Emmanuel Lepage Vallee 88c65a71dd textbox: Rename `align` to `halign`.
`halign` is used in multiple place in the API. Once upon a time,
Awesome only supported horizontal widgets, but this era has long
passed.

Fix #3640
2022-09-06 16:11:04 -07:00
Lucas Schwiderski ab6df1280f
bug(github_actions): Skip unreliable test
Signed-off-by: Lucas Schwiderski <lucas@lschwiderski.de>
2021-06-26 14:50:40 +02:00
Lucas Schwiderski d9711c3f48
feat(github_actions): Improve test
Signed-off-by: Lucas Schwiderski <lucas@lschwiderski.de>
2021-05-06 20:05:04 +02:00
Lucas Schwiderski 5c3b739c25
fix(github_actions): Fix clients lingering into subsequent tests
On GitHub Actions, clients created in some tests take too long to close
and still exist when the next test has started. This can affect certain
tests that rely on a specific client count or simply produce a race
condition within `scan` in `awesome.c`.

Signed-off-by: Lucas Schwiderski <lucas@lschwiderski.de>
2021-05-06 20:04:48 +02:00
Emmanuel Lepage Vallee 067bcaca60 client: Rename the `manage` and `unmanage` signals.
They currently fit the general concept of a `request::` in the sense
that they are not property related and have "request handlers".

The commit also add deprecation for signals.

The reason for this fits within the larger standardization project.
Non-namespaced signals will eventually be renamed. This has started
a long time ago.

What is old is new again. Once upon a time, there was a `startup`
parameter to the `manage` signal. It is now back in the form of
a context.

Finally, this commit removes the `manage` section of `rc.lua`. It no
longer did anything worthy of being in the config. Each of its
important parts have been moved out over the years and the last
remaining bit is always required anyway. The code has been moved
to `client.lua`.
2020-01-11 14:43:56 -08:00
Emmanuel Lepage Vallee 2c08c2fa39 quality: Port all legacy `:buttons()` to `.buttons`. 2019-10-06 03:50:56 -04:00
Sergey Vlasov f08599a6d6 test-leak-client.lua: Test GC for titlebar widgets (#2830)
Add a test which recreates the titlebar for an existing client and
checks that widgets from the old titlebar instance can be GC'd.

Signed-off-by: Sergey Vlasov <sigprof@gmail.com>
2019-07-22 17:35:18 +03:00
Kevin Zander c3461b535c gears: Move awful.util.table to gears.table (#1641)
* Move table functions out of awful.util into new gears.table

* travis: Use v9999 prefix for full requests

Make sure no newly deprecated functions are used

* Move all `awful.util.table.*` calls to `gears.table.*` calls
Move table test functions from awful/util_spec to new gears/table_spec
Change awful.util.subsets call to gears.math.subsets in awful/key.lua
2017-03-08 15:18:33 -05:00
Uli Schlachter 0d8106c6dd test-leak-client.lua: Wait for c:kill() to be done
Signed-off-by: Uli Schlachter <psychon@znc.in>
2017-01-02 19:34:41 +01:00
Daniel Hahler 68de588f21 tests: fix indenting/style (#1303)
Basically:

> for f in **/*.lua; do vim '+set sw=4' '+norm gg=G' '+wq' "$f"; done
2016-12-27 21:39:08 +01:00
Uli Schlachter e18bece3df Make tests more reliable on "early errors"
When e.g. test-leaks.lua fails, it will cause a Lua error before starting the
test runner. This means that the test will just hang, because nothing causes
awesome to quit.

Handle this by starting a timer when the test runner is loaded and quitting
awesome in there if no test run was started yet. This only works if all tests
load the runner before doing anything that could fail, so the require("_runner")
is moved to the beginning in every test.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2016-03-06 10:20:45 +01:00
Uli Schlachter 432908dd26 Fix test-leak-client.lua under LuaCov
Both the test runner and the wibox use gears.timer.delayed_call(). The test
runner uses this to call steps and the wibox uses it to trigger redraws. When
running under LuaCov, the Lua code becomes slow enough that the wibox didn't
redraw yet when the leak check is run. This causes the check to fail, because
the client is still referenced by the tasklist and thus cannot be garbage
collected.

Fix this by waiting one more iteration before running the leak check.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2016-02-12 09:26:29 +01:00
Uli Schlachter e2d75dbcfd Add a functional testing for leaks with clients
This opens xterm, closes it and makes sure that the client object representing
xterm is GC'able at the end. The test will fail currently.

Signed-off-by: Uli Schlachter <psychon@znc.in>
2016-02-04 18:24:53 +01:00