const EventEmitter = require('events').EventEmitter;
module.exports = class Test extends EventEmitter {
constructor() {
super();
}
method() {
this.emit('default', data);
}
let obj = new require('./file1');
obj.on('default', function (data) {
console.log(" ...default");
});
obj.method();
let obj = new (require('./file1'));