Skip to content
This repository has been archived by the owner on Oct 4, 2023. It is now read-only.

Commit

Permalink
Fix test-installed-snaps.js by ensuring sudo is set to true for insta…
Browse files Browse the repository at this point in the history
…ll or remove operations (#150)
  • Loading branch information
David Barth authored Feb 7, 2017
1 parent e6499d0 commit f97ee18
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion tests/run-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ if [ ! -d "$modules_dir" ]; then
modules_dir="../node_modules"
fi

echo 'Run selenium tests for snapweb service on given IP'
echo "Run selenium tests for snapweb on $host:$port with user:$user/$sudo"
USER=$user HOST=$host PORT=$port SUDO=$sudo $modules_dir/.bin/wdio -b https://$2:4201
exitcode=$?

Expand Down
4 changes: 2 additions & 2 deletions tests/utils/snap-cmd-util.js
Original file line number Diff line number Diff line change
Expand Up @@ -103,11 +103,11 @@ SnapUtil.prototype.getToken = function() {
}

SnapUtil.prototype.installSnap = function(name) {
return this._promisifyExec('snap install ' + name, this.isSudoRequired);
return this._promisifyExec('snap install ' + name, true);
}

SnapUtil.prototype.removeSnap = function(name) {
return this._promisifyExec('snap remove ' + name, this.isSudoRequired);
return this._promisifyExec('snap remove ' + name, true);
}

SnapUtil.prototype.snapVersion = function() {
Expand Down

0 comments on commit f97ee18

Please sign in to comment.