index.js
function generateFakeDataForSchema(schemaName) {
  return new RSVP.Promise(function (resolve, reject) {
    agolSchemas.getSchema(schemaName).then(function (schema) {
      // Generate fake data
      var fakeData = jsf(schema);
      // return fake data
      resolve(fakeData);
    });
  });
}
function generateFakeDataForSchema(schemaName) {
  return new RSVP.Promise(function (resolve, reject) {
    agolSchemas.getSchema(schemaName).then(function (schema) {
      // Generate fake data
      var fakeData = jsf(schema);
      // return fake data
      resolve(fakeData);
    });
  });
}
function generateFakeDataForSchema ( schemaName ) { return new RSVP . Promise ( function ( resolve , reject ) { agolSchemas . getSchema ( schemaName ) . then ( function ( schema ) { // Generate fake data var fakeData = jsf ( schema ) ; // return fake data resolve ( fakeData ) ; } ) ; } ) ; }
Generate fake data for a certain schema
@param {string} schemaName Name of the schema to be generated.
@returns {object} Promise. The resolve function has one parameter representing the generated fake data.
Generate fake data for a certain schema