import Application from 'appkit/app';
import Router from 'appkit/router';
function startApp(attrs) {
var App;
var attributes = Ember.merge({
// useful Test defaults
rootElement: '#ember-testing',
// LOG_ACTIVE_GENERATION:false,
// LOG_VIEW_LOOKUPS: false
LOG_ACTIVE_GENERATION: true,
LOG_MODULE_RESOLVER: true,
LOG_TRANSITIONS: true,
LOG_TRANSITIONS_INTERNAL: true,
LOG_VIEW_LOOKUPS: true
}, attrs); // but you can override;
Ember.run.join(function(){
App = Application.create(attributes);
App.setupForTesting();
App.injectTestHelpers();
});
Router.reopen({
location: 'none'
});
App.reset(); // this shouldn't be needed, i want to be able to "start an app at a specific URL"
return App;
}
export default startApp;
//問:我想重寫默認的應用程序:適配器我試圖app.register其指向休息//適配器在我的實際應用與燈具適配器方法,但它不//工作任何指針。灰燼應用套件如何重寫應用適配器驗收測試
謝謝阿爾法。 – mz17
@MayankGupta我知道很多時間已經過去了,但如果這個答案解決了你的問題,不要忘記將它標記爲已接受的答案。 =) – Alpha