Merge "Fix data binding for project state"
This commit is contained in:
@@ -129,10 +129,10 @@
|
||||
|
||||
promises.push(this.$.restAPI.getProjectConfig(this.project).then(
|
||||
config => {
|
||||
this._projectConfig = config;
|
||||
if (!this._projectConfig.state) {
|
||||
this._projectConfig.state = STATES.active.value;
|
||||
if (!config.state) {
|
||||
config.state = STATES.active.value;
|
||||
}
|
||||
this._projectConfig = config;
|
||||
this._loading = false;
|
||||
}));
|
||||
|
||||
|
||||
@@ -247,6 +247,7 @@ limitations under the License.
|
||||
test('state gets set correctly', done => {
|
||||
element._loadProject().then(() => {
|
||||
assert.equal(element._projectConfig.state, 'ACTIVE');
|
||||
assert.equal(element.$.stateSelect.bindValue, 'ACTIVE');
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user