|
@@ -1,5 +1,6 @@
|
|
BABYLONDEVTOOLS.Loader.require('../validation/validation.js')
|
|
BABYLONDEVTOOLS.Loader.require('../validation/validation.js')
|
|
.load(function() {
|
|
.load(function() {
|
|
|
|
+ var needInit = false;
|
|
document.getElementById("run").addEventListener("click", function() {
|
|
document.getElementById("run").addEventListener("click", function() {
|
|
// Loading tests
|
|
// Loading tests
|
|
var xhr = new XMLHttpRequest();
|
|
var xhr = new XMLHttpRequest();
|
|
@@ -14,6 +15,10 @@ BABYLONDEVTOOLS.Loader.require('../validation/validation.js')
|
|
// Run tests
|
|
// Run tests
|
|
var index = 0;
|
|
var index = 0;
|
|
|
|
|
|
|
|
+ if (needInit) {
|
|
|
|
+ init();
|
|
|
|
+ }
|
|
|
|
+
|
|
var title = document.getElementById("sceneName").value.toLowerCase();
|
|
var title = document.getElementById("sceneName").value.toLowerCase();
|
|
for (var index = 0; index < config.tests.length; index++) {
|
|
for (var index = 0; index < config.tests.length; index++) {
|
|
if (config.tests[index].title.toLowerCase() === title) {
|
|
if (config.tests[index].title.toLowerCase() === title) {
|
|
@@ -23,6 +28,7 @@ BABYLONDEVTOOLS.Loader.require('../validation/validation.js')
|
|
|
|
|
|
runTest(index, function() {
|
|
runTest(index, function() {
|
|
BABYLON.Engine.LastCreatedEngine.dispose();
|
|
BABYLON.Engine.LastCreatedEngine.dispose();
|
|
|
|
+ needInit = true;
|
|
});
|
|
});
|
|
}
|
|
}
|
|
}, false);
|
|
}, false);
|