2020-04-21 11:47:02 +02:00
|
|
|
const {assert} = require('chai');
|
2020-04-23 15:26:54 +02:00
|
|
|
const Event = require('../src/r3/r3-event.js');
|
2020-04-21 11:47:02 +02:00
|
|
|
|
2021-10-01 12:40:04 +02:00
|
|
|
//GENERATED_COMPONENT_IMPORTS_START
|
|
|
|
const ComponentCode = require('../src/r3/r3-component/./r3-component-code.js');
|
|
|
|
const ComponentDOM = require('../src/r3/r3-component/./r3-component-d-o-m.js');
|
|
|
|
const ComponentCanvas = require('../src/r3/r3-component/./r3-component-canvas.js');
|
|
|
|
const ComponentGraphics = require('../src/r3/r3-component/./r3-component-graphics.js');
|
|
|
|
const ComponentImage = require('../src/r3/r3-component/./r3-component-image.js');
|
|
|
|
const ComponentMaterial = require('../src/r3/r3-component/./r3-component-material.js');
|
|
|
|
const ComponentMesh = require('../src/r3/r3-component/./r3-component-mesh.js');
|
|
|
|
const ComponentTexture = require('../src/r3/r3-component/./r3-component-texture.js');
|
|
|
|
const ComponentInput = require('../src/r3/r3-component/./r3-component-input.js');
|
|
|
|
const ComponentTouch = require('../src/r3/r3-component/./r3-component-touch.js');
|
|
|
|
//GENERATED_COMPONENT_IMPORTS_END
|
|
|
|
|
|
|
|
//GENERATED_ENTITY_IMPORTS_START
|
|
|
|
const EntitySlider = require('../src/r3/r3-entity/./r3-entity-slider.js');
|
|
|
|
//GENERATED_ENTITY_IMPORTS_END
|
|
|
|
|
|
|
|
//GENERATED_RUNTIME_IMPORTS_START
|
|
|
|
const RuntimeCoder = require('../src/r3/r3-runtime/./r3-runtime-coder.js');
|
|
|
|
const RuntimeCodeMirror = require('../src/r3/r3-runtime/./r3-runtime-code-mirror.js');
|
|
|
|
const RuntimeDOM = require('../src/r3/r3-runtime/./r3-runtime-d-o-m.js');
|
|
|
|
const RuntimeDocument = require('../src/r3/r3-runtime/./r3-runtime-document.js');
|
|
|
|
const RuntimeGUI = require('../src/r3/r3-runtime/./r3-runtime-g-u-i.js');
|
|
|
|
const RuntimeControlKit = require('../src/r3/r3-runtime/./r3-runtime-control-kit.js');
|
|
|
|
const RuntimeGraphics = require('../src/r3/r3-runtime/./r3-runtime-graphics.js');
|
|
|
|
const RuntimeThree = require('../src/r3/r3-runtime/./r3-runtime-three.js');
|
|
|
|
const RuntimeImage = require('../src/r3/r3-runtime/./r3-runtime-image.js');
|
|
|
|
const RuntimeNodeJSImage = require('../src/r3/r3-runtime/./r3-runtime-node-j-s-image.js');
|
|
|
|
const RuntimeWebImage = require('../src/r3/r3-runtime/./r3-runtime-web-image.js');
|
|
|
|
const RuntimePhysics = require('../src/r3/r3-runtime/./r3-runtime-physics.js');
|
|
|
|
const RuntimeBullet = require('../src/r3/r3-runtime/./r3-runtime-bullet.js');
|
|
|
|
const RuntimeSocket = require('../src/r3/r3-runtime/./r3-runtime-socket.js');
|
|
|
|
const RuntimeStatistics = require('../src/r3/r3-runtime/./r3-runtime-statistics.js');
|
|
|
|
const RuntimeStats = require('../src/r3/r3-runtime/./r3-runtime-stats.js');
|
|
|
|
//GENERATED_RUNTIME_IMPORTS_END
|
|
|
|
|
|
|
|
//GENERATED_R3_OBJECT_IMPORTS_START
|
|
|
|
const Project = require('../src/r3/r3-object/./r3-project.js');
|
|
|
|
//GENERATED_R3_OBJECT_IMPORTS_END
|
|
|
|
|
2021-10-01 06:08:34 +02:00
|
|
|
describe('R3 Tests', () => {
|
2020-04-21 11:47:02 +02:00
|
|
|
|
|
|
|
it (
|
2021-10-01 08:36:52 +02:00
|
|
|
'R3 loads',
|
2020-04-21 11:47:02 +02:00
|
|
|
() => {
|
|
|
|
|
2021-10-01 06:08:34 +02:00
|
|
|
const R3 = require('../src/r3/');
|
2020-04-21 11:47:02 +02:00
|
|
|
|
2021-10-01 06:08:34 +02:00
|
|
|
assert.typeOf(R3.Version, 'string');
|
|
|
|
assert.typeOf(R3.CompileDate, 'string');
|
2020-04-21 11:47:02 +02:00
|
|
|
|
2021-10-01 06:08:34 +02:00
|
|
|
console.log('R3 Version : ' + R3.Version);
|
|
|
|
console.log('R3 Compile Date : ' + R3.CompileDate);
|
|
|
|
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
|
|
|
it (
|
2021-10-01 08:36:52 +02:00
|
|
|
'Creation of all components succeed',
|
2021-10-01 06:08:34 +02:00
|
|
|
() => {
|
|
|
|
|
2021-10-01 12:40:04 +02:00
|
|
|
//GENERATED_COMPONENT_CREATE_START
|
|
|
|
const componentCode = new ComponentCode();
|
|
|
|
const componentDOM = new ComponentDOM();
|
|
|
|
const componentCanvas = new ComponentCanvas();
|
|
|
|
const componentGraphics = new ComponentGraphics();
|
|
|
|
const componentImage = new ComponentImage();
|
|
|
|
const componentMaterial = new ComponentMaterial();
|
|
|
|
const componentMesh = new ComponentMesh();
|
|
|
|
const componentTexture = new ComponentTexture();
|
|
|
|
const componentInput = new ComponentInput();
|
|
|
|
const componentTouch = new ComponentTouch();
|
|
|
|
//GENERATED_COMPONENT_CREATE_END
|
|
|
|
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
|
|
|
it (
|
|
|
|
'Creation of all entities succeed',
|
|
|
|
() => {
|
|
|
|
|
|
|
|
//GENERATED_ENTITY_CREATE_START
|
|
|
|
const entitySlider = new EntitySlider();
|
|
|
|
//GENERATED_ENTITY_CREATE_END
|
|
|
|
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
|
|
|
it (
|
|
|
|
'Creation of all runtimes succeed',
|
|
|
|
() => {
|
|
|
|
|
|
|
|
//GENERATED_RUNTIME_CREATE_START
|
|
|
|
const runtimeCoder = new RuntimeCoder();
|
|
|
|
const runtimeCodeMirror = new RuntimeCodeMirror();
|
|
|
|
const runtimeDOM = new RuntimeDOM();
|
|
|
|
const runtimeDocument = new RuntimeDocument();
|
|
|
|
const runtimeGUI = new RuntimeGUI();
|
|
|
|
const runtimeControlKit = new RuntimeControlKit();
|
|
|
|
const runtimeGraphics = new RuntimeGraphics();
|
|
|
|
const runtimeThree = new RuntimeThree();
|
|
|
|
const runtimeImage = new RuntimeImage();
|
|
|
|
const runtimeNodeJSImage = new RuntimeNodeJSImage();
|
|
|
|
const runtimeWebImage = new RuntimeWebImage();
|
|
|
|
const runtimePhysics = new RuntimePhysics();
|
|
|
|
const runtimeBullet = new RuntimeBullet();
|
|
|
|
const runtimeSocket = new RuntimeSocket();
|
|
|
|
const runtimeStatistics = new RuntimeStatistics();
|
|
|
|
const runtimeStats = new RuntimeStats();
|
|
|
|
//GENERATED_RUNTIME_CREATE_END
|
|
|
|
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
|
|
|
it (
|
|
|
|
'Creation of all objects succeed',
|
|
|
|
() => {
|
2021-10-01 06:08:34 +02:00
|
|
|
|
2021-10-01 12:40:04 +02:00
|
|
|
//GENERATED_R3_OBJECT_CREATE_START
|
|
|
|
const project = new Project();
|
|
|
|
//GENERATED_R3_OBJECT_CREATE_END
|
2020-04-21 11:47:02 +02:00
|
|
|
|
|
|
|
}
|
|
|
|
);
|
|
|
|
|
|
|
|
});
|
|
|
|
|