mirror of https://gitee.com/bigwinds/arangodb
Fixed tests for newest frontend changes
This commit is contained in:
parent
6aca853065
commit
0b44a05a1b
|
@ -89,6 +89,10 @@
|
|||
});
|
||||
},
|
||||
|
||||
isSystem: function() {
|
||||
return this.get("system");
|
||||
},
|
||||
|
||||
isDevelopment: function() {
|
||||
return this.get("development");
|
||||
}
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
<div class="header_left">
|
||||
<input type="button" class="open button-success" disabled="true" value="Open" />
|
||||
<input id="app-switch-mode" type="button" class="switch-mode button-warning" value="<%=app.get('development')?'Production':'Development'%>" />
|
||||
<input type="button" class="delete button-danger" value="Delete" disabled="<%=app.get('isSystem')%>" />
|
||||
<input type="button" class="delete button-danger" value="Delete" <%=app.isSystem()?"disabled":""%> />
|
||||
</div>
|
||||
<div class="header_right">
|
||||
<h3>
|
||||
|
|
|
@ -114,7 +114,7 @@
|
|||
},
|
||||
|
||||
showConfigureDialog: function(e) {
|
||||
if ((this._appConfig).keys.length === 0) {
|
||||
if (Object.keys(this._appConfig).length === 0) {
|
||||
e.stopPropagation();
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -35,7 +35,20 @@
|
|||
var myFoxx = new window.Foxx();
|
||||
expect(myFoxx.isNew()).toBeFalsy();
|
||||
});
|
||||
|
||||
it("system apps should know it", function() {
|
||||
var myFoxx = new window.Foxx({
|
||||
system: true
|
||||
});
|
||||
expect(myFoxx.isSystem()).toBeTruthy();
|
||||
});
|
||||
|
||||
it("non system apps should know it", function() {
|
||||
var myFoxx = new window.Foxx({
|
||||
system: false
|
||||
});
|
||||
expect(myFoxx.isSystem()).toBeFalsy();
|
||||
});
|
||||
|
||||
describe("mode chages", function() {
|
||||
|
||||
|
|
|
@ -65,6 +65,7 @@
|
|||
});
|
||||
|
||||
it("should be able to delete the app", function() {
|
||||
|
||||
runs(function() {
|
||||
deleteButton.click();
|
||||
});
|
||||
|
@ -153,7 +154,7 @@
|
|||
});
|
||||
|
||||
it("the button should be enabled", function() {
|
||||
expect($(buttonId).prop("disabled")).toEqual(false);
|
||||
expect($(buttonId).hasClass("disabled")).toEqual(false);
|
||||
});
|
||||
|
||||
it("should utilize a modal dialog", function() {
|
||||
|
@ -205,7 +206,7 @@
|
|||
});
|
||||
|
||||
it("the button should be disabled", function() {
|
||||
expect($(buttonId).prop("disabled")).toEqual(true);
|
||||
expect($(buttonId).hasClass("disabled")).toEqual(true);
|
||||
});
|
||||
|
||||
});
|
||||
|
|
Loading…
Reference in New Issue