mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-02-03 23:00:14 -05:00
21 lines
530 B
JavaScript
21 lines
530 B
JavaScript
import Ember from 'ember';
|
|
import Application from '../../app';
|
|
import config from '../../config/environment';
|
|
|
|
const {assign, run} = Ember;
|
|
|
|
export default function startApp(attrs) {
|
|
let attributes = assign({}, config.APP);
|
|
let application;
|
|
|
|
// use defaults, but you can override;
|
|
attributes = assign(attributes, attrs);
|
|
|
|
run(function () {
|
|
application = Application.create(attributes);
|
|
application.setupForTesting();
|
|
application.injectTestHelpers();
|
|
});
|
|
|
|
return application;
|
|
}
|