Run Breeze Entity Manager in Node <p>How is everyone else testing their breeze client-side entity functions? </p> <p>I have entity <code>Ticket</code> that has <code>Tags</code> navigation property with hundreds of <code>Tags</code>. </p> <p>Each <code>Tag</code> has many boolean properties <code>IsChanged</code>, <code>IsTagged</code>, <code>IsReplaced</code>, etc </p> <p>Each tag also has an <code>Item</code> navigation property. The <code>Item</code> has <code>ItemType</code> (<code>ItemType</code> is another entity with properties like <code>TestFrequency</code>), <code>IsCondemened</code>, etc </p> <p>I have functions on the <code>Ticket</code> and <code>Tag</code> and <code>Item</code> entities, that filter, map, and reduce over all the related entities, to summarize all the tags and items for each <code>Ticket</code>.</p> <p>I need to test these functions, and I'm finding that to create all these objects by hand for my tests is a ton of duplication of code.</p> <p>If I could just have a json file on disk with some sample entities straight from the database, then not only would it eliminate a bunch of boilerplate factory code, but I could be sure that whenever my data schema changes in EF on server side, my json would also change to reflect that.</p> <p><strong>Here's where I'm scratching my head:</strong></p> <p><strong><em>I need to be able to run breeze-client in node so my npm script can grab the data and save it to disk with one command.</em></strong></p> <p>I cannot find ONE complete solution ANYWHERE for using breeze-client in node.</p> <p>There is <a href="http://stackoverflow.com/questions/20383252/using-breeze-js-entitymanager-from-within-node">another question</a> that asks about it 3 years ago, and no definitive working answer was ever given.</p> <p>Also this <a href="https://github.com/Breeze/breeze.js/issues/95#issuecomment-102691456" rel="nofollow">github issue</a> last year, with one comment coming really close to a full answer, but the actual implementation of the adapter was never shared.</p> <p>With the vast number of people who use the breeze library, I feel like I'm doing something wrong when the only way I can see to reliably test my entities is to run breeze-client in node, and NO ONE ELSE seems interested in running breeze-client in node.</p> <p>I was trying to figure out how to create an ajaxAdapter myself for node, but I keep striking out.</p> <p>Please can someone either give me a clue for how to make a node ajaxAdapter, or tell me a better way to be testing my business logic on my breeze entities?</p>