spec: Tests for remote ES6 class
This commit is contained in:
parent
67324ce732
commit
f610e332b3
2 changed files with 66 additions and 0 deletions
29
spec/fixtures/module/class.js
vendored
Normal file
29
spec/fixtures/module/class.js
vendored
Normal file
|
@ -0,0 +1,29 @@
|
|||
'use strict';
|
||||
|
||||
let value = 'old';
|
||||
|
||||
class BaseClass {
|
||||
method() {
|
||||
return 'method';
|
||||
}
|
||||
|
||||
get readonly() {
|
||||
return 'readonly';
|
||||
}
|
||||
|
||||
get value() {
|
||||
return value;
|
||||
}
|
||||
|
||||
set value(val) {
|
||||
value = val;
|
||||
}
|
||||
}
|
||||
|
||||
class DerivedClass extends BaseClass {
|
||||
}
|
||||
|
||||
module.exports = {
|
||||
base: new BaseClass,
|
||||
derived: new DerivedClass,
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue