#
# Check LightDM runs the script hooks correctly for autologin and the greeter
#

[Seat:*]
display-setup-script=test-script-hook DISPLAY-SETUP
display-stopped-script=test-script-hook DISPLAY-STOPPED
greeter-setup-script=test-script-hook GREETER-SETUP
session-setup-script=test-script-hook SESSION-SETUP
session-cleanup-script=test-script-hook SESSION-CLEANUP
autologin-user=have-password1
user-session=default

#?*START-DAEMON
#?RUNNER DAEMON-START

# One X server should start by default
#?XSERVER-0 START VT=7 SEAT=seat0

# Daemon connects when X server is ready
#?*XSERVER-0 INDICATE-READY
#?XSERVER-0 INDICATE-READY
#?XSERVER-0 ACCEPT-CONNECT

# Script hooks run
#?SCRIPT-HOOK DISPLAY-SETUP XDG_SEAT=seat0
#?SCRIPT-HOOK SESSION-SETUP XDG_SEAT=seat0 USER=have-password1

# Session starts
#?SESSION-X-0 START XDG_SEAT=seat0 XDG_VTNR=7 XDG_GREETER_DATA_DIR=.*/have-password1 XDG_SESSION_TYPE=x11 XDG_SESSION_DESKTOP=default USER=have-password1
#?LOGIN1 ACTIVATE-SESSION SESSION=c0
#?XSERVER-0 ACCEPT-CONNECT
#?SESSION-X-0 CONNECT-XSERVER

# Logout session
#?*SESSION-X-0 LOGOUT

# Script hook runs
#?SCRIPT-HOOK SESSION-CLEANUP XDG_SEAT=seat0 USER=have-password1

# X server stops
#?XSERVER-0 TERMINATE SIGNAL=15

# Script hooks run
#?SCRIPT-HOOK DISPLAY-STOPPED XDG_SEAT=seat0

# X server starts
#?XSERVER-0 START VT=7 SEAT=seat0

# Daemon connects when X server is ready
#?*XSERVER-0 INDICATE-READY
#?XSERVER-0 INDICATE-READY
#?XSERVER-0 ACCEPT-CONNECT

# Script hooks run
#?SCRIPT-HOOK DISPLAY-SETUP XDG_SEAT=seat0
#?SCRIPT-HOOK GREETER-SETUP XDG_SEAT=seat0 USER=.*

# Greeter starts
#?GREETER-X-0 START XDG_SEAT=seat0 XDG_VTNR=7 XDG_SESSION_CLASS=greeter
#?LOGIN1 ACTIVATE-SESSION SESSION=c1
#?XSERVER-0 ACCEPT-CONNECT
#?GREETER-X-0 CONNECT-XSERVER
#?GREETER-X-0 CONNECT-TO-DAEMON
#?GREETER-X-0 CONNECTED-TO-DAEMON

# Cleanup
#?*STOP-DAEMON
#?GREETER-X-0 TERMINATE SIGNAL=15
#?XSERVER-0 TERMINATE SIGNAL=15

# Script hooks run
#?SCRIPT-HOOK DISPLAY-STOPPED XDG_SEAT=seat0

# Finish cleanup
#?RUNNER DAEMON-EXIT STATUS=0
