File: 01_remove_display.lua

package info (click to toggle)
notion 4.0.2%2Bdfsg-5
  • links: PTS, VCS
  • area: main
  • in suites: bullseye
  • size: 4,676 kB
  • sloc: ansic: 47,508; sh: 2,096; makefile: 603; perl: 270
file content (19 lines) | stat: -rw-r--r-- 642 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
-- Removing screens happens asynchronously, so we just check we start with 2 screens,
-- remove one, and then leave checking that one was removed up to the next test.

os.execute("cp xinerama/fakexinerama-2monitors xinerama/.fakexinerama");

mod_xinerama.refresh();

if (notioncore.find_screen_id(1) == Nil) then
  return "Initial number of screens should be 2, second screen not found"
elseif (notioncore.find_screen_id(2) ~= Nil) then
  return "Initial number of screens should be 2, third screen found"
end

-- Remove one display:
os.execute("cp xinerama/fakexinerama-1monitor xinerama/.fakexinerama")

mod_xinerama.refresh()

return "ok"