-
Notifications
You must be signed in to change notification settings - Fork 157
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b3d6a03
commit d6a0c3b
Showing
4 changed files
with
56 additions
and
57 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
coverage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,20 @@ | ||
import Vue from 'vue'; | ||
import HelloComponent from './resources/Hello.vue'; | ||
import Vue from 'vue' | ||
import HelloComponent from './resources/Hello.vue' | ||
|
||
describe('Test suite for HelloComponent', () => { | ||
it('Test data msg', () => { | ||
const ClonedComponent = Vue.extend(HelloComponent); | ||
const NewComponent = new ClonedComponent({ | ||
data() { | ||
return { | ||
msg: 'I am a cool message', | ||
}; | ||
}, | ||
}).$mount(); | ||
expect(HelloComponent.data().msg).toBe('Welcome to Your Vue.js App'); | ||
expect(NewComponent.msg).toBe('I am a cool message'); | ||
expect(NewComponent.headingClasses).toBeDefined(); | ||
NewComponent.toggleClass(); | ||
expect(NewComponent.isCrazy).toBeTruthy(); | ||
}); | ||
}); | ||
it('Test data msg', () => { | ||
const ClonedComponent = Vue.extend(HelloComponent) | ||
const NewComponent = new ClonedComponent({ | ||
data () { | ||
return { | ||
msg: 'I am a cool message' | ||
} | ||
} | ||
}).$mount() | ||
expect(HelloComponent.data().msg).toBe('Welcome to Your Vue.js App') | ||
expect(NewComponent.msg).toBe('I am a cool message') | ||
expect(NewComponent.headingClasses).toBeDefined() | ||
NewComponent.toggleClass() | ||
expect(NewComponent.isCrazy).toBeTruthy() | ||
}) | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,20 @@ | ||
import Vue from 'vue'; | ||
import HelloComponent from './resources/Hello.vue'; | ||
import Vue from 'vue' | ||
import HelloComponent from './resources/Hello.vue' | ||
|
||
describe('Test suite for HelloComponent', () => { | ||
it('Test data msg', () => { | ||
const ClonedComponent = Vue.extend(HelloComponent); | ||
const NewComponent = new ClonedComponent({ | ||
data() { | ||
return { | ||
msg: 'I am a cool message', | ||
}; | ||
}, | ||
}).$mount(); | ||
expect(HelloComponent.data().msg).toBe('Welcome to Your Vue.js App'); | ||
expect(NewComponent.msg).toBe('I am a cool message'); | ||
expect(NewComponent.headingClasses).toBeDefined(); | ||
NewComponent.toggleClass(); | ||
expect(NewComponent.isCrazy).toBeTruthy(); | ||
}); | ||
}); | ||
it('Test data msg', () => { | ||
const ClonedComponent = Vue.extend(HelloComponent) | ||
const NewComponent = new ClonedComponent({ | ||
data () { | ||
return { | ||
msg: 'I am a cool message' | ||
} | ||
} | ||
}).$mount() | ||
expect(HelloComponent.data().msg).toBe('Welcome to Your Vue.js App') | ||
expect(NewComponent.msg).toBe('I am a cool message') | ||
expect(NewComponent.headingClasses).toBeDefined() | ||
NewComponent.toggleClass() | ||
expect(NewComponent.isCrazy).toBeTruthy() | ||
}) | ||
}) |