Test your Google App Script
npm install app-script-mock



```
npm install --save-dev app-script-mockbefore
And before all your tests (you can use mocha's )`js`
const extendGlobal = require('app-script-mock');
describe('[...]', () => {
before(() => {
extendGlobal(global);
});
});
js
const functionThatCreatesFormsBasedOnSpreadsheet = () => {
//Your code here that uses FormApp/DriveApp/SpreadsheetApp
return form.getId();
}
describe('Should create a form with 3 questions based on spreadsheet', () => {
const createdFormId = functionThatCreatesFormsBasedOnSpreadsheet();
assert.equal(3, FormApp.openById(createdFormId).getItems().length);
})
``