ui: explicit reference to window.localStorage

This commit is contained in:
Mahmood Ali
2020-04-03 14:31:19 -04:00
parent 5562abd7bf
commit 4a92a27db7
2 changed files with 6 additions and 6 deletions

View File

@@ -10,8 +10,8 @@ module('Acceptance | exec', function(hooks) {
setupMirage(hooks);
hooks.beforeEach(async function() {
localStorage.clear();
sessionStorage.clear();
window.localStorage.clear();
window.sessionStorage.clear();
server.create('agent');
server.create('node');
@@ -347,7 +347,7 @@ module('Acceptance | exec', function(hooks) {
let mockSockets = Service.extend({
getTaskStateSocket(taskState, command) {
assert.equal(command, '/sh');
localStorage.getItem('nomadExecCommand', JSON.stringify('/sh'));
window.localStorage.getItem('nomadExecCommand', JSON.stringify('/sh'));
assert.step('Socket built');
@@ -407,7 +407,7 @@ module('Acceptance | exec', function(hooks) {
});
test('a persisted customised command is recalled', async function(assert) {
localStorage.setItem('nomadExecCommand', JSON.stringify('/bin/sh'));
window.localStorage.setItem('nomadExecCommand', JSON.stringify('/bin/sh'));
let taskGroup = this.job.task_groups.models[0];
let task = taskGroup.tasks.models[0];

View File

@@ -17,8 +17,8 @@ module('Acceptance | tokens', function(hooks) {
setupMirage(hooks);
hooks.beforeEach(function() {
localStorage.clear();
sessionStorage.clear();
window.localStorage.clear();
window.sessionStorage.clear();
server.create('agent');
node = server.create('node');