'use strict';
const
    uploadmanager = require('uploadmanager').init(),
    event = require('myevents');

var t = 0;

describe('upload', () => {
    it('upload  file', (done) => {
        uploadmanager.addTask('F:\\s0.exe');
        uploadmanager.addTask('F:\\s1.exe');
        uploadmanager.addTask('F:\\s2.exe');
        uploadmanager.addTask('F:\\s3.exe');
        uploadmanager.addTask('F:\\s4.exe');
        uploadmanager.addTask('F:\\s5.exe');
        uploadmanager.addTask('F:\\s6.exe');

        event.on('upload_complete_ctr', (ab) => {
            t++;
            if (t >= 4) {
                done();
                console.log(uploadmanager.taskList.stopUploadTasks)
            }
        });

    });
});

