GNOME Bugzilla – Bug 723698
Implement smoketesting for multiple sessions
Last modified: 2014-04-25 13:20:54 UTC
Not tested, and I'm afraid I can't setup a continuous testing VM. But it should work in theory.
Created attachment 268189 [details] [review] Implement smoketesting for multiple sessions Write an AccountsService file before smoketesting to force a specific session, so that we can run smoketests on gnome core and gnome classic.
Review of attachment 268189 [details] [review]: This is not gonna work - in _prepareDisks user is not yet created
Created attachment 274669 [details] [review] Create user via accountservice dbus interface This patch is assuming that created user will have uid 1000, but I'm not sure how to read user's UID correctly
Created attachment 274670 [details] [review] Add a new 'smoketest-classic' task which starts gnome-classic
Created attachment 274671 [details] [review] Wait longer during smoketests after gnome-session has staretd running Before bug 728449 is solved, lets just wait longer to get a nice screenshot
(In reply to comment #2) > Review of attachment 268189 [details] [review]: > > This is not gonna work - in _prepareDisks user is not yet created Why is that a problem? We're not running the image until later, and we don't need the UID, just the name.
(In reply to comment #6) > (In reply to comment #2) > > Review of attachment 268189 [details] [review] [details]: > > > > This is not gonna work - in _prepareDisks user is not yet created > > Why is that a problem? We're not running the image until later, and we don't > need the UID, just the name. Tried this locally - and it didn't work. Probably accountservice overwrites the file later, as the user is being created later (in testbase.execute) and via useradd utility, but that's just a guess
Created attachment 274717 [details] [review] Wait for shell to startup
Fixed in https://git.gnome.org/browse/gnome-continuous/commit/?id=5c0cce9acd54e8f36dc3a5780abb30d764c815c9
Review of attachment 274669 [details] [review]: I'm *definitely* a fan of using the accountsservice API rather than useradd directly, as we end up testing accountsservice too. But Ray should probably review this one...it might be worth creating accountsservice commandline utilities. ::: src/js/libqa.js @@ +236,3 @@ let addUserService = '[Unit]\n\ Description=Add user %s\n\ +After=accountsservice.service\n\ Don't need this, dbus activation will start accountsservice on demand for us.
Review of attachment 274670 [details] [review]: ::: src/js/libqa.js @@ +235,3 @@ } + if (params.session != null) { + setSessionCommand = Format.vprintf(commandTemplate, ['/User1000', 'User.SetXSession', 'string:' + params.session]) Jasper did this in a different way by writing to /var/lib/AccountsService directly which is ugly, but works. I like this approach more - do you want to rebase this patch on master and drop Jasper's code to write to /var/lib? ::: src/js/tasks/task-smoketest.js @@ +53,3 @@ + + +const TaskSmoketestClassic = new Lang.Class({ Or we could apply just this bit on master now.
Review of attachment 274717 [details] [review]: This looks good to me, once the shell patch has landed.