Skip to content

Commit

Permalink
Merge pull request #36 from donejs/feature/upgrade-steal
Browse files Browse the repository at this point in the history
Feature/upgrade steal
  • Loading branch information
matthewp authored Dec 16, 2016
2 parents 401d73a + 4e6de00 commit 4d44e06
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 16 deletions.
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
language: node_js
node_js: 5.8
script: npm test
addons:
firefox: "48.0"
before_install:
- "export DISPLAY=:99.0"
- "sh -e /etc/init.d/xvfb start"
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,29 +26,29 @@
"can-component": "^3.0.3",
"can-list": "^3.0.1",
"can-map": "^3.0.3",
"can-map-define": "^3.0.1",
"can-map-define": "^3.0.2",
"can-route": "^3.0.5",
"funcunit": "^3.1.0",
"lodash.template": "^4.4.0",
"steal": "^0.16.43",
"steal-qunit": "0.1.4",
"steal-tools": "^0.16.8",
"steal": "^1.0.3",
"steal-qunit": "1.0.0",
"steal-tools": "^1.0.1",
"testee": "^0.3.0"
},
"homepage": "https://github.com/donejs/autorender",
"system": {
"steal": {
"npmAlgorithm": "flat",
"directories": {
"lib": "src"
}
},
"dependencies": {
"can-route": "^3.0.5",
"can-stache": "^3.0.13",
"can-util": "^3.0.13",
"can-stache": "^3.0.15",
"can-util": "^3.1.0",
"can-view-import": "^3.0.3",
"can-view-model": "^3.1.2",
"can-zone": "^0.6.0",
"steal-stache": "^3.0.3"
"steal-stache": "^3.0.4"
}
}
2 changes: 1 addition & 1 deletion src/template.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 1 addition & 2 deletions src/template.txt
Original file line number Diff line number Diff line change
Expand Up @@ -50,11 +50,10 @@ define(<%= imports %>, function(<%= args %>){
plugins: [xhrZone, systemImportZone]
}).run(function(){
var state = autorender.state = new autorender.viewModel;

var docEl = document.documentElement;
domData.set.call(docEl, "viewModel", state);

route.map(state);
route.data = state;
route.ready();

autorender.rerender();
Expand Down
2 changes: 1 addition & 1 deletion test/autorender_test.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
var QUnit = require("steal-qunit");
var F = require("funcunit");

require("./unit");
//require("./unit");

F.attach(QUnit);

Expand Down
14 changes: 11 additions & 3 deletions test/basics/test.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
</head>
<body>
<script>
window.Testee = {};

window.QUnit = window.parent.QUnit;
window.removeMyself = window.parent.removeMyself;
</script>
Expand All @@ -13,9 +15,15 @@
var canViewModel = require("can-view-model");
var Zone = require("can-zone");

new Zone().run(function() {
return System.import('test/basics/index.stache!done-autorender');
}).then(function() {
System.import('test/basics/index.stache!done-autorender')
.then(function(){
return new Promise(function(resolve, reject){
setTimeout(function(){
resolve();
}, 500);
});
})
.then(function() {
var vm = canViewModel(document.documentElement);

if(window.QUnit) {
Expand Down
2 changes: 1 addition & 1 deletion test/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ var stealTools = require("steal-tools");
stealTools.build({
config: __dirname + "/../package.json!npm",
main: "test/basics/index.stache!done-autorender",
bundlesPath: "test/basics/dist/bundles"
}, {
dest: "test/basics/dist",
quiet: true
});

0 comments on commit 4d44e06

Please sign in to comment.