We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No description provided.
The text was updated successfully, but these errors were encountered:
Example:
'use strict'; // !-- FOR TESTS let wrapper = function (options) { // --! // ===================================================== // <EXAMPLE> let Beelzebub = require('../../'); let bz = Beelzebub(options || { verbose: true }); class MySubTask extends Beelzebub.Tasks { default () { this.logger.log('MySubTask default'); return this.$sequence('.task1', '.task2'); } task1 () { this.logger.log('MySubTask task1'); } task2 () { this.logger.log('MySubTask task2'); } } class MyTasks extends Beelzebub.Tasks { constructor (config) { super(config); this.$setDefault('myDefault'); } myDefault () { this.logger.log('MyTasks myDefault'); } } class MyRootLevel extends Beelzebub.Tasks { constructor (config) { super(config); this.$useAsRoot(); } $init () { this.$addSubTasks(MySubTask); } task1 () { this.logger.log('MyRootLevel task1'); } task2 () { this.logger.log('MyRootLevel task2'); } } bz.add(MyRootLevel); bz.add(MyTasks); let p = bz.run( 'task1', 'MySubTask', 'MySubTask.task1', 'MyTasks', 'MyTasks.myDefault' ); /* Output: MyRootLevel task1 MySubTask default MySubTask task1 MySubTask task2 MySubTask task1 MyTasks myDefault MyTasks myDefault */ // </EXAMPLE> // ===================================================== // !-- FOR TESTS return p.then(() => { return bz; }); }; module.exports = wrapper; // if not running in test, then run wrapper if (typeof global.it !== 'function') wrapper(); // --!
Sorry, something went wrong.
No branches or pull requests
No description provided.
The text was updated successfully, but these errors were encountered: