trailsjs / trailpack-sequelize

:package: Sequelize.js Trailpack http://sequelizejs.com
MIT License
5 stars 9 forks source link

Footprints associations #2

Closed jaumard closed 8 years ago

jaumard commented 8 years ago

Implement methods for footprints associations.

tjwebb commented 8 years ago

Bountysource

tjwebb commented 8 years ago

Bounty increased to $150

PlasmaPower commented 8 years ago

To clarify, an implementation of this would consist solely of a FootprintService.js (and folders + index.js) like this one, correct?

Edit: Oh, and tests for it. For the tests should I use SQLite and remove the DB before the tests?

jaumard commented 8 years ago

@PlasmaPower yes at the end OneToOne, OneToMany, ManyToMany associations have to works with createAssociation, updateAssociation, findAssociation, destroyAssociation of the FootprintService with all tests to validate it's working.

Some tests are already done for this module and yes it use SQLite, normally you don't need to remove the DB because the migration is set to drop so all is clear each time. (https://github.com/trailsjs/trailpack-sequelize/blob/master/test/services/FootprintService.test.js#L137-L243) for now tests doesn't cover every associations type so some need to be created.

Hope it's more clear now :) if not let us know.

PlasmaPower commented 8 years ago

@jaumard Makes sense - I'll begin work on this :).

Edit: Oops - I totally missed that you already had a FootprintService made, it just needed more added to it. This will be easier.

jaumard commented 8 years ago

@PlasmaPower great ! Yeah all is set up normally just the sequelize implementation is missing for the FootprintService :)

PlasmaPower commented 8 years ago

@tjwebb, Could you look over my PR for this? I think it's done.