11cb0ef41Sopenharmony_ci'use strict'; 21cb0ef41Sopenharmony_ciconst common = require('../common'); 31cb0ef41Sopenharmony_ci 41cb0ef41Sopenharmony_ciconst { Writable } = require('stream'); 51cb0ef41Sopenharmony_ci 61cb0ef41Sopenharmony_ci{ 71cb0ef41Sopenharmony_ci const w = new Writable({ 81cb0ef41Sopenharmony_ci write(chunk, encoding, callback) { 91cb0ef41Sopenharmony_ci callback(null); 101cb0ef41Sopenharmony_ci }, 111cb0ef41Sopenharmony_ci final(callback) { 121cb0ef41Sopenharmony_ci queueMicrotask(callback); 131cb0ef41Sopenharmony_ci } 141cb0ef41Sopenharmony_ci }); 151cb0ef41Sopenharmony_ci w.end(); 161cb0ef41Sopenharmony_ci w.destroy(); 171cb0ef41Sopenharmony_ci 181cb0ef41Sopenharmony_ci w.on('prefinish', common.mustNotCall()); 191cb0ef41Sopenharmony_ci w.on('finish', common.mustNotCall()); 201cb0ef41Sopenharmony_ci w.on('close', common.mustCall()); 211cb0ef41Sopenharmony_ci} 22