Skip to content

Commit 51f7aa3

Browse files
committed
chore(tests): fix "[Vue warn]: Component is missing template or render function"
1 parent b056159 commit 51f7aa3

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

src/__tests__/decorator.spec.js

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ describe('@Socket() decorator', () => {
1010

1111
it('uses method name as a listener name', () => {
1212
class App extends Vue {
13+
render() {
14+
return '';
15+
}
16+
1317
@Socket()
1418
tweet() {
1519
}
@@ -24,6 +28,10 @@ describe('@Socket() decorator', () => {
2428

2529
it('uses given name as a listener name', () => {
2630
class App extends Vue {
31+
render() {
32+
return '';
33+
}
34+
2735
@Socket('tweet')
2836
onTweet() {
2937
}
@@ -39,6 +47,10 @@ describe('@Socket() decorator', () => {
3947
it('doesn\'t throw an error when decorator used on the computed property and no methods defined on component', () => {
4048
expect(() => {
4149
class App extends Vue { // eslint-disable-line no-unused-vars
50+
render() {
51+
return '';
52+
}
53+
4254
@Socket('tweet')
4355
get tweets() {
4456
}
@@ -49,6 +61,10 @@ describe('@Socket() decorator', () => {
4961
it('doesn\'t throw an error when decorator used on the computed property and some methods defined on component', () => {
5062
expect(() => {
5163
class App extends Vue { // eslint-disable-line no-unused-vars
64+
render() {
65+
return '';
66+
}
67+
5268
@Socket('tweet')
5369
get tweets() {
5470
}
@@ -61,6 +77,10 @@ describe('@Socket() decorator', () => {
6177

6278
it('doesn\'t define sockets on component when decorator used on the computed property', () => {
6379
class App extends Vue {
80+
render() {
81+
return '';
82+
}
83+
6484
@Socket('tweet')
6585
get tweets() {
6686
}

0 commit comments

Comments
 (0)