booster.tests.js 412 B

12345678910111213141516
  1. var BoosterService = require('../game/machine/BoosterService');
  2. var Users = require('../database/repositories/users.js');
  3. Users.login({
  4. username: 'nikatlas',
  5. password: 'mafalda'
  6. })
  7. .then((user) => Users.getUser(user.token))
  8. .then((user) => {
  9. console.log(user);
  10. //BoosterService.givePack(user.username);
  11. return user;
  12. })
  13. .then((user) => {
  14. BoosterService.getUserBoosters(user.username).then(console.log);
  15. });