karma spec updates

This commit is contained in:
Phil Hughes 2017-11-01 09:26:16 +00:00
parent 7c331ac951
commit b20381204a
No known key found for this signature in database
GPG key ID: 32245528C52E0F9F
4 changed files with 14 additions and 10 deletions

View file

@ -122,7 +122,9 @@
// we need to do this to prevent noteForm inconsistent content warning
// this is something we intentionally do so we need to recover the content
this.note.note = noteText;
this.$refs.noteBody.$refs.noteForm.note = noteText; // TODO: This could be better
if (this.$refs.noteBody) {
this.$refs.noteBody.$refs.noteForm.note = noteText; // TODO: This could be better
}
},
},
created() {

View file

@ -98,7 +98,7 @@ Once you confirm %{deleteAccount}, it cannot be undone or recovered.`),
@toggle="toggleOpen"
@submit="onSubmit">
<template slot="body" scope="props">
<template slot="body" slot-scope="props">
<p v-html="props.text"></p>
<form

View file

@ -431,9 +431,9 @@ describe('AppComponent', () => {
});
it('should render groups tree', (done) => {
vm.groups = [mockParentGroupItem];
vm.store.state.groups = [mockParentGroupItem];
vm.isLoading = false;
vm.pageInfo = mockPageInfo;
vm.store.state.pageInfo = mockPageInfo;
Vue.nextTick(() => {
expect(vm.$el.querySelector('.groups-list-tree-container')).toBeDefined();
done();

View file

@ -42,12 +42,14 @@ describe('Markdown field component', () => {
beforeEach(() => {
spyOn(Vue.http, 'post').and.callFake(() => new Promise((resolve) => {
resolve({
json() {
return {
body: '<p>markdown preview</p>',
};
},
setTimeout(() => {
resolve({
json() {
return {
body: '<p>markdown preview</p>',
};
},
});
});
}));