提交 3c41b9d5 编写于 作者: M munrocket@pm.me

Package.json: lighter dependencies

上级 f32e6f14
......@@ -41,7 +41,9 @@ jobs:
with:
node-version: 10
- name: Install packages
run: npm ci && npm run build-test
run: npm ci && npm ci --prefix test
- name: Build
run: npm run build
- name: === Unit testing ===
run: npm run test-unit
......@@ -63,7 +65,9 @@ jobs:
with:
node-version: 10
- name: Install packages
run: npm ci && sudo apt-get install xvfb && npm run build
run: npm ci && npm ci --prefix test && sudo apt-get install xvfb
- name: Build
run: npm run build
- name: === E2E testing ===
run: xvfb-run --auto-servernum npm run test-e2e
......
.DS_Store
*.swp
.project
node_modules
.idea/
.vscode/
npm-debug.log
.jshintrc
.vs/
test/unit/three.*.unit.js
\ No newline at end of file
**/node_modules
test/unit/build
此差异已折叠。
......@@ -47,7 +47,6 @@
"scripts": {
"start": "npm run dev",
"build": "rollup -c utils/build/rollup.config.js",
"build-test": "rollup -c test/rollup.unit.config.js",
"build-closure": "rollup -c utils/build/rollup.config.js && google-closure-compiler --warning_level=VERBOSE --jscomp_off=globalThis --jscomp_off=checkTypes --externs utils/build/externs.js --language_in=ECMASCRIPT5_STRICT --js build/three.js --js_output_file build/three.min.js",
"build-examples": "rollup -c utils/build/rollup-examples.config.js",
"dev": "concurrently --names \"ROLLUP,HTTP\" -c \"bgBlue.bold,bgGreen.bold\" \"rollup -c utils/build/rollup.config.js -w -m inline\" \"http-server -c-1 -p 8080\"",
......@@ -55,7 +54,7 @@
"lint-docs": "eslint docs --ext html",
"lint-examples": "eslint examples/jsm --ext js --ext ts --ignore-pattern libs && tsc -p utils/build/tsconfig-examples.lint.json",
"test-lint": "eslint src --ext js --ext ts && tsc -p utils/build/tsconfig.lint.json",
"test-unit": "npm run build-test && qunit -r failonlyreporter test/unit/three.source.unit.js",
"test-unit": "npm run unit --prefix test",
"test-e2e": "node test/e2e/puppeteer.js",
"test-e2e-cov": "node test/e2e/check-coverage.js",
"make-screenshot": "cross-env MAKE=true node test/e2e/puppeteer.js"
......@@ -89,17 +88,10 @@
"eslint": "^6.8.0",
"eslint-config-mdcs": "^5.0.0",
"eslint-plugin-html": "^6.0.2",
"failonlyreporter": "^1.0.0",
"google-closure-compiler": "20200224.0.0",
"http-server": "^0.12.3",
"image-output": "^2.4.2",
"pixelmatch": "5.2.0",
"pngjs": "5.0.0",
"puppeteer": "2.1.1",
"qunit": "^2.10.0",
"rollup": "^2.10.0",
"rollup-plugin-buble": "^0.19.8",
"serve-handler": "^6.1.2",
"typescript": "^3.9.2"
},
"jspm": {
......
......@@ -43,7 +43,7 @@ if ( subES.length + subSE.length + subEF.length + subFE.length === 0 ) {
} else {
if ( subES.length > 0 ) console.red( 'Add screenshots for example(s): ' + subES.join(' ') );
if ( subES.length > 0 ) console.red( 'Make screenshot for example(s): ' + subES.join(' ') );
if ( subSE.length > 0 ) console.red( 'Remove unnecessary screenshot(s): ' + subSE.join(' ') );
if ( subEF.length > 0 ) console.red( 'Add description in file.js for example(s): ' + subEF.join(' ') );
if ( subFE.length > 0 ) console.red( 'Remove description in file.js for example(s): ' + subFE.join(' ') );
......
......@@ -2,6 +2,17 @@
* @author munrocket / https://github.com/munrocket
*/
try {
require( 'puppeteer' );
} catch {
console.log( '\x1b[31mError! You not installed dependencies. Please run `npm i --prefix test`\x1b[37m' );
process.exit( 1 );
}
const puppeteer = require( 'puppeteer' );
const handler = require( 'serve-handler' );
const http = require( 'http' );
......@@ -14,6 +25,14 @@ const port = 1234;
const pixelThreshold = 0.2; // threshold error in one pixel
const maxFailedPixels = 0.05; // total failed pixels
const networkTimeout = 600;
const networkTax = 2000; // additional timeout for resources size
const pageSizeMinTax = 1.0; // in mb, when networkTax = 0
const pageSizeMaxTax = 5.0; // in mb, when networkTax = networkTax
const renderTimeout = 1200;
const maxAttemptId = 3; // progresseve attempts
const progressFunc = n => 1 + n;
const exceptionList = [
'index',
......@@ -33,14 +52,6 @@ const exceptionList = [
] : [] );
const networkTimeout = 600;
const networkTax = 2000; // additional timeout for resources size
const pageSizeMinTax = 1.0; // in mb, when networkTax = 0
const pageSizeMaxTax = 5.0; // in mb, when networkTax = networkTax
const renderTimeout = 1200;
const maxAttemptId = 3; // progresseve attempts
const progressFunc = n => 1 + n;
console.green = ( msg ) => console.log( `\x1b[32m${ msg }\x1b[37m` );
console.red = ( msg ) => console.log( `\x1b[31m${ msg }\x1b[37m` );
console.null = () => {};
......
此差异已折叠。
{
"name": "test-deps-intaller",
"version": "1.0.0",
"description": "This package hiding test dependincies from main repo because puppeteer is pretty big.",
"scripts": {
"unit": "rollup -c rollup.unit.config.js && qunit -r failonlyreporter unit/build/three.source.unit.js"
},
"devDependencies": {
"failonlyreporter": "^1.0.0",
"image-output": "^2.4.2",
"pixelmatch": "^5.2.0",
"pngjs": "^5.0.0",
"puppeteer": "2.1.1",
"qunit": "^2.10.0",
"serve-handler": "^6.1.2"
},
"license": "MIT"
}
try {
require( 'qunit' );
} catch {
console.log( '\x1b[31mError! You not installed dependencies. Please run `npm i --prefix test`\x1b[37m' );
process.exit( 1 );
}
function glsl() {
return {
......@@ -26,7 +38,7 @@ function glsl() {
export default [
// editor unit conf
{
input: 'test/three.editor.unit.js',
input: 'unit/three.editor.unit.js',
plugins: [
glsl()
],
......@@ -35,7 +47,7 @@ export default [
{
format: 'umd',
name: 'THREE',
file: 'test/unit/three.editor.unit.js',
file: 'unit/build/three.editor.unit.js',
intro: 'QUnit.module( "Editor", () => {',
outro: '} );',
indent: '\t',
......@@ -44,7 +56,7 @@ export default [
},
// example unit conf
{
input: 'test/three.example.unit.js',
input: 'unit/three.example.unit.js',
plugins: [
glsl()
],
......@@ -53,7 +65,7 @@ export default [
{
format: 'umd',
name: 'THREE',
file: 'test/unit/three.example.unit.js',
file: 'unit/build/three.example.unit.js',
intro: 'QUnit.module( "Example", () => {',
outro: '} );',
indent: '\t',
......@@ -62,7 +74,7 @@ export default [
},
// source unit conf
{
input: 'test/three.source.unit.js',
input: 'unit/three.source.unit.js',
plugins: [
glsl()
],
......@@ -71,7 +83,7 @@ export default [
{
format: 'umd',
name: 'THREE',
file: 'test/unit/three.source.unit.js',
file: 'unit/build/three.source.unit.js',
intro: 'QUnit.module( "Source", () => {',
outro: '} );',
indent: '\t',
......
/**
* @author TristanVALCKE / https://github.com/Itee
*/
// TODO (Itee) Editor is not es6 module so care to include order !!!
// TODO: all views could not be testable, waiting modular code before implement units tests on them
import './unit/qunit-utils.js';
//editor
import './unit/editor/Command.tests';
import './unit/editor/Config.tests';
import './unit/editor/Editor.tests';
import './unit/editor/History.tests';
import './unit/editor/Loader.tests';
import './unit/editor/Player.tests';
import './unit/editor/Script.tests';
import './unit/editor/Menubar.tests';
import './unit/editor/Menubar.Add.tests';
import './unit/editor/Menubar.Edit.tests';
import './unit/editor/Menubar.Examples.tests';
import './unit/editor/Menubar.File.tests';
import './unit/editor/Menubar.Help.tests';
import './unit/editor/Menubar.Play.tests';
import './unit/editor/Menubar.Status.tests';
import './unit/editor/Menubar.View.tests';
import './unit/editor/Sidebar.tests';
import './unit/editor/Sidebar.Animation.tests';
import './unit/editor/Sidebar.Geometry.tests';
import './unit/editor/Sidebar.Geometry.BoxGeometry.tests';
import './unit/editor/Sidebar.Geometry.BufferGeometry.tests';
import './unit/editor/Sidebar.Geometry.CircleGeometry.tests';
import './unit/editor/Sidebar.Geometry.CylinderGeometry.tests';
import './unit/editor/Sidebar.Geometry.Geometry.tests';
import './unit/editor/Sidebar.Geometry.IcosahedronGeometry.tests';
import './unit/editor/Sidebar.Geometry.LatheGeometry.tests';
import './unit/editor/Sidebar.Geometry.Modifiers.tests';
import './unit/editor/Sidebar.Geometry.PlaneGeometry.tests';
import './unit/editor/Sidebar.Geometry.SphereGeometry.tests';
import './unit/editor/Sidebar.Geometry.TeapotBufferGeometry.tests';
import './unit/editor/Sidebar.Geometry.TorusGeometry.tests';
import './unit/editor/Sidebar.Geometry.TorusKnotGeometry.tests';
import './unit/editor/Sidebar.History.tests';
import './unit/editor/Sidebar.Material.tests';
import './unit/editor/Sidebar.Object.tests';
import './unit/editor/Sidebar.Project.tests';
import './unit/editor/Sidebar.Properties.tests';
import './unit/editor/Sidebar.Scene.tests';
import './unit/editor/Sidebar.Script.tests';
import './unit/editor/Sidebar.Settings.tests';
import './unit/editor/Storage.tests';
import './unit/editor/Toolbar.tests';
import './unit/editor/Viewport.tests';
import './unit/editor/Viewport.Info.tests';
//editor/commands
import './unit/editor/commands/AddObjectCommand.tests';
import './unit/editor/commands/AddScriptCommand.tests';
import './unit/editor/commands/MoveObjectCommand.tests';
import './unit/editor/commands/MultiCmdsCommand.tests';
import './unit/editor/commands/RemoveObjectCommand.tests';
import './unit/editor/commands/RemoveScriptCommand.tests';
import './unit/editor/commands/SetColorCommand.tests';
import './unit/editor/commands/SetGeometryCommand.tests';
import './unit/editor/commands/SetGeometryValueCommand.tests';
import './unit/editor/commands/SetMaterialColorCommand.tests';
import './unit/editor/commands/SetMaterialCommand.tests';
import './unit/editor/commands/SetMaterialMapCommand.tests';
import './unit/editor/commands/SetMaterialValueCommand.tests';
import './unit/editor/commands/SetPositionCommand.tests';
import './unit/editor/commands/SetRotationCommand.tests';
import './unit/editor/commands/SetScaleCommand.tests';
import './unit/editor/commands/SetSceneCommand.tests';
import './unit/editor/commands/SetScriptValueCommand.tests';
import './unit/editor/commands/SetUuidCommand.tests';
import './unit/editor/commands/SetValueCommand.tests';
//editor/others
/**
* @author TristanVALCKE / https://github.com/Itee
*/
import './unit/qunit-utils.js';
import './unit/example/utils/BufferGeometryUtils.tests';
import './unit/example/exporters/GLTFExporter.tests';
import './unit/example/loaders/GLTFLoader.tests';
import './unit/example/objects/Lensflare.tests';
/**
* @author TristanVALCKE / https://github.com/Itee
*/
import './unit/qunit-utils.js';
//src
import './unit/src/constants.tests';
import './unit/src/polyfills.tests';
import './unit/src/utils.tests';
//src/animation
import './unit/src/animation/AnimationAction.tests';
import './unit/src/animation/AnimationClip.tests';
import './unit/src/animation/AnimationMixer.tests';
import './unit/src/animation/AnimationObjectGroup.tests';
import './unit/src/animation/AnimationUtils.tests';
import './unit/src/animation/KeyframeTrack.tests';
import './unit/src/animation/PropertyBinding.tests';
import './unit/src/animation/PropertyMixer.tests';
//src/animation/tracks
import './unit/src/animation/tracks/BooleanKeyframeTrack.tests';
import './unit/src/animation/tracks/ColorKeyframeTrack.tests';
import './unit/src/animation/tracks/NumberKeyframeTrack.tests';
import './unit/src/animation/tracks/QuaternionKeyframeTrack.tests';
import './unit/src/animation/tracks/StringKeyframeTrack.tests';
import './unit/src/animation/tracks/VectorKeyframeTrack.tests';
//src/audio
import './unit/src/audio/Audio.tests';
import './unit/src/audio/AudioAnalyser.tests';
import './unit/src/audio/AudioContext.tests';
import './unit/src/audio/AudioListener.tests';
import './unit/src/audio/PositionalAudio.tests';
//src/cameras
import './unit/src/cameras/ArrayCamera.tests';
import './unit/src/cameras/Camera.tests';
import './unit/src/cameras/CubeCamera.tests';
import './unit/src/cameras/OrthographicCamera.tests';
import './unit/src/cameras/PerspectiveCamera.tests';
import './unit/src/cameras/StereoCamera.tests';
//src/core
import './unit/src/core/BufferAttribute.tests';
import './unit/src/core/BufferGeometry.tests';
import './unit/src/core/Clock.tests';
import './unit/src/core/DirectGeometry.tests';
import './unit/src/core/EventDispatcher.tests';
import './unit/src/core/Face3.tests';
import './unit/src/core/Geometry.tests';
import './unit/src/core/InstancedBufferAttribute.tests';
import './unit/src/core/InstancedBufferGeometry.tests';
import './unit/src/core/InstancedInterleavedBuffer.tests';
import './unit/src/core/InterleavedBuffer.tests';
import './unit/src/core/InterleavedBufferAttribute.tests';
import './unit/src/core/Layers.tests';
import './unit/src/core/Object3D.tests';
import './unit/src/core/Raycaster.tests';
import './unit/src/core/Uniform.tests';
//src/extras
import './unit/src/extras/ShapeUtils.tests';
//src/extras/core
import './unit/src/extras/core/Curve.tests';
import './unit/src/extras/core/CurvePath.tests';
import './unit/src/extras/core/Font.tests';
import './unit/src/extras/core/Interpolations.tests';
import './unit/src/extras/core/Path.tests';
import './unit/src/extras/core/Shape.tests';
import './unit/src/extras/core/ShapePath.tests';
//src/extras/curves
import './unit/src/extras/curves/ArcCurve.tests';
import './unit/src/extras/curves/CatmullRomCurve3.tests';
import './unit/src/extras/curves/CubicBezierCurve.tests';
import './unit/src/extras/curves/CubicBezierCurve3.tests';
import './unit/src/extras/curves/EllipseCurve.tests';
import './unit/src/extras/curves/LineCurve.tests';
import './unit/src/extras/curves/LineCurve3.tests';
import './unit/src/extras/curves/QuadraticBezierCurve.tests';
import './unit/src/extras/curves/QuadraticBezierCurve3.tests';
import './unit/src/extras/curves/SplineCurve.tests';
//src/extras/objects
import './unit/src/extras/objects/ImmediateRenderObject.tests';
//src/geometries
import './unit/src/geometries/BoxGeometry.tests';
import './unit/src/geometries/CircleGeometry.tests';
import './unit/src/geometries/ConeGeometry.tests';
import './unit/src/geometries/CylinderGeometry.tests';
import './unit/src/geometries/DodecahedronGeometry.tests';
import './unit/src/geometries/EdgesGeometry.tests';
import './unit/src/geometries/ExtrudeGeometry.tests';
import './unit/src/geometries/IcosahedronGeometry.tests';
import './unit/src/geometries/LatheGeometry.tests';
import './unit/src/geometries/OctahedronGeometry.tests';
import './unit/src/geometries/ParametricGeometry.tests';
import './unit/src/geometries/PlaneGeometry.tests';
import './unit/src/geometries/PolyhedronGeometry.tests';
import './unit/src/geometries/RingGeometry.tests';
import './unit/src/geometries/ShapeGeometry.tests';
import './unit/src/geometries/SphereGeometry.tests';
import './unit/src/geometries/TetrahedronGeometry.tests';
import './unit/src/geometries/TextGeometry.tests';
import './unit/src/geometries/TorusGeometry.tests';
import './unit/src/geometries/TorusKnotGeometry.tests';
import './unit/src/geometries/TubeGeometry.tests';
import './unit/src/geometries/WireframeGeometry.tests';
//src/helpers
import './unit/src/helpers/ArrowHelper.tests';
import './unit/src/helpers/AxesHelper.tests';
import './unit/src/helpers/Box3Helper.tests';
import './unit/src/helpers/BoxHelper.tests';
import './unit/src/helpers/CameraHelper.tests';
import './unit/src/helpers/DirectionalLightHelper.tests';
import './unit/src/helpers/GridHelper.tests';
import './unit/src/helpers/HemisphereLightHelper.tests';
import './unit/src/helpers/PlaneHelper.tests';
import './unit/src/helpers/PointLightHelper.tests';
import './unit/src/helpers/PolarGridHelper.tests';
import './unit/src/helpers/SkeletonHelper.tests';
import './unit/src/helpers/SpotLightHelper.tests';
//src/lights
import './unit/src/lights/AmbientLight.tests';
import './unit/src/lights/DirectionalLight.tests';
import './unit/src/lights/DirectionalLightShadow.tests';
import './unit/src/lights/HemisphereLight.tests';
import './unit/src/lights/Light.tests';
import './unit/src/lights/LightShadow.tests';
import './unit/src/lights/PointLight.tests';
import './unit/src/lights/RectAreaLight.tests';
import './unit/src/lights/SpotLight.tests';
import './unit/src/lights/SpotLightShadow.tests';
//src/loaders
import './unit/src/loaders/AnimationLoader.tests';
import './unit/src/loaders/AudioLoader.tests';
import './unit/src/loaders/BufferGeometryLoader.tests';
import './unit/src/loaders/Cache.tests';
import './unit/src/loaders/CompressedTextureLoader.tests';
import './unit/src/loaders/CubeTextureLoader.tests';
import './unit/src/loaders/DataTextureLoader.tests';
import './unit/src/loaders/FileLoader.tests';
import './unit/src/loaders/FontLoader.tests';
import './unit/src/loaders/ImageLoader.tests';
import './unit/src/loaders/Loader.tests';
import './unit/src/loaders/LoaderUtils.tests';
import './unit/src/loaders/LoadingManager.tests';
import './unit/src/loaders/MaterialLoader.tests';
import './unit/src/loaders/ObjectLoader.tests';
import './unit/src/loaders/TextureLoader.tests';
//src/materials
import './unit/src/materials/LineBasicMaterial.tests';
import './unit/src/materials/LineDashedMaterial.tests';
import './unit/src/materials/Material.tests';
import './unit/src/materials/MeshBasicMaterial.tests';
import './unit/src/materials/MeshDepthMaterial.tests';
import './unit/src/materials/MeshDistanceMaterial.tests';
import './unit/src/materials/MeshLambertMaterial.tests';
import './unit/src/materials/MeshNormalMaterial.tests';
import './unit/src/materials/MeshPhongMaterial.tests';
import './unit/src/materials/MeshPhysicalMaterial.tests';
import './unit/src/materials/MeshStandardMaterial.tests';
import './unit/src/materials/MeshToonMaterial.tests';
import './unit/src/materials/PointsMaterial.tests';
import './unit/src/materials/RawShaderMaterial.tests';
import './unit/src/materials/ShaderMaterial.tests';
import './unit/src/materials/ShadowMaterial.tests';
import './unit/src/materials/SpriteMaterial.tests';
//src/math
import './unit/src/math/Box2.tests';
import './unit/src/math/Box3.tests';
import './unit/src/math/Color.tests';
import './unit/src/math/Cylindrical.tests';
import './unit/src/math/Euler.tests';
import './unit/src/math/Frustum.tests';
import './unit/src/math/Interpolant.tests';
import './unit/src/math/Line3.tests';
import './unit/src/math/MathUtils.tests';
import './unit/src/math/Matrix3.tests';
import './unit/src/math/Matrix4.tests';
import './unit/src/math/Plane.tests';
import './unit/src/math/Quaternion.tests';
import './unit/src/math/Ray.tests';
import './unit/src/math/Sphere.tests';
import './unit/src/math/Spherical.tests';
import './unit/src/math/Triangle.tests';
import './unit/src/math/Vector2.tests';
import './unit/src/math/Vector3.tests';
import './unit/src/math/Vector4.tests';
//src/math/interpolants
import './unit/src/math/interpolants/CubicInterpolant.tests';
import './unit/src/math/interpolants/DiscreteInterpolant.tests';
import './unit/src/math/interpolants/LinearInterpolant.tests';
import './unit/src/math/interpolants/QuaternionLinearInterpolant.tests';
//src/objects
import './unit/src/objects/Bone.tests';
import './unit/src/objects/Group.tests';
import './unit/src/objects/Line.tests';
import './unit/src/objects/LineLoop.tests';
import './unit/src/objects/LineSegments.tests';
import './unit/src/objects/LOD.tests';
import './unit/src/objects/Mesh.tests';
import './unit/src/objects/Points.tests';
import './unit/src/objects/Skeleton.tests';
import './unit/src/objects/SkinnedMesh.tests';
import './unit/src/objects/Sprite.tests';
//src/renderers
import './unit/src/renderers/WebGLRenderer.tests';
import './unit/src/renderers/WebGLRenderTarget.tests';
import './unit/src/renderers/WebGLCubeRenderTarget.tests';
//src/renderers/shaders
import './unit/src/renderers/shaders/ShaderChunk.tests';
import './unit/src/renderers/shaders/ShaderLib.tests';
import './unit/src/renderers/shaders/UniformsLib.tests';
import './unit/src/renderers/shaders/UniformsUtils.tests';
//src/renderers/webgl
import './unit/src/renderers/webgl/WebGLAttributes.tests';
import './unit/src/renderers/webgl/WebGLBackground.tests';
import './unit/src/renderers/webgl/WebGLBufferRenderer.tests';
import './unit/src/renderers/webgl/WebGLCapabilities.tests';
import './unit/src/renderers/webgl/WebGLClipping.tests';
import './unit/src/renderers/webgl/WebGLExtensions.tests';
import './unit/src/renderers/webgl/WebGLGeometries.tests';
import './unit/src/renderers/webgl/WebGLIndexedBufferRenderer.tests';
import './unit/src/renderers/webgl/WebGLLights.tests';
import './unit/src/renderers/webgl/WebGLMorphtargets.tests';
import './unit/src/renderers/webgl/WebGLObjects.tests';
import './unit/src/renderers/webgl/WebGLProgram.tests';
import './unit/src/renderers/webgl/WebGLPrograms.tests';
import './unit/src/renderers/webgl/WebGLProperties.tests';
import './unit/src/renderers/webgl/WebGLRenderLists.tests';
import './unit/src/renderers/webgl/WebGLShader.tests';
import './unit/src/renderers/webgl/WebGLShadowMap.tests';
import './unit/src/renderers/webgl/WebGLState.tests';
import './unit/src/renderers/webgl/WebGLTextures.tests';
import './unit/src/renderers/webgl/WebGLUniforms.tests';
import './unit/src/renderers/webgl/WebGLUtils.tests';
//src/scenes
import './unit/src/scenes/Fog.tests';
import './unit/src/scenes/FogExp2.tests';
import './unit/src/scenes/Scene.tests';
//src/textures
import './unit/src/textures/CanvasTexture.tests';
import './unit/src/textures/CompressedTexture.tests';
import './unit/src/textures/CubeTexture.tests';
import './unit/src/textures/DataTexture.tests';
import './unit/src/textures/DepthTexture.tests';
import './unit/src/textures/Texture.tests';
import './unit/src/textures/VideoTexture.tests';
......@@ -3,22 +3,22 @@
<head>
<meta charset="utf-8">
<title>ThreeJS Unit Tests - Using Files in /src</title>
<link rel="stylesheet" href="../../node_modules/qunit/qunit/qunit.css">
<link rel="stylesheet" href="../node_modules/qunit/qunit/qunit.css">
</head>
<body>
<div id="qunit"></div>
<div id="qunit-fixture"></div>
<script src="../../node_modules/qunit/qunit/qunit.js"></script>
<script src="../node_modules/qunit/qunit/qunit.js"></script>
<!-- We need three.js because qunit-utils cannot be es6 module and use THREE stuff... -->
<script src="../../build/three.js"></script>
<!-- add sources to test below -->
<!-- <script src="three.editor.unit.js"></script> -->
<script src="three.source.unit.js"></script>
<script src="three.example.unit.js"></script>
<!-- <script src="build/three.editor.unit.js"></script> -->
<script src="build/three.source.unit.js"></script>
<script src="build/three.example.unit.js"></script>
</body>
</html>
/**
* @author TristanVALCKE / https://github.com/Itee
*/
// TODO (Itee) Editor is not es6 module so care to include order !!!
// TODO: all views could not be testable, waiting modular code before implement units tests on them
import './qunit-utils.js';
//editor
import './editor/Command.tests';
import './editor/Config.tests';
import './editor/Editor.tests';
import './editor/History.tests';
import './editor/Loader.tests';
import './editor/Player.tests';
import './editor/Script.tests';
import './editor/Menubar.tests';
import './editor/Menubar.Add.tests';
import './editor/Menubar.Edit.tests';
import './editor/Menubar.Examples.tests';
import './editor/Menubar.File.tests';
import './editor/Menubar.Help.tests';
import './editor/Menubar.Play.tests';
import './editor/Menubar.Status.tests';
import './editor/Menubar.View.tests';
import './editor/Sidebar.tests';
import './editor/Sidebar.Animation.tests';
import './editor/Sidebar.Geometry.tests';
import './editor/Sidebar.Geometry.BoxGeometry.tests';
import './editor/Sidebar.Geometry.BufferGeometry.tests';
import './editor/Sidebar.Geometry.CircleGeometry.tests';
import './editor/Sidebar.Geometry.CylinderGeometry.tests';
import './editor/Sidebar.Geometry.Geometry.tests';
import './editor/Sidebar.Geometry.IcosahedronGeometry.tests';
import './editor/Sidebar.Geometry.LatheGeometry.tests';
import './editor/Sidebar.Geometry.Modifiers.tests';
import './editor/Sidebar.Geometry.PlaneGeometry.tests';
import './editor/Sidebar.Geometry.SphereGeometry.tests';
import './editor/Sidebar.Geometry.TeapotBufferGeometry.tests';
import './editor/Sidebar.Geometry.TorusGeometry.tests';
import './editor/Sidebar.Geometry.TorusKnotGeometry.tests';
import './editor/Sidebar.History.tests';
import './editor/Sidebar.Material.tests';
import './editor/Sidebar.Object.tests';
import './editor/Sidebar.Project.tests';
import './editor/Sidebar.Properties.tests';
import './editor/Sidebar.Scene.tests';
import './editor/Sidebar.Script.tests';
import './editor/Sidebar.Settings.tests';
import './editor/Storage.tests';
import './editor/Toolbar.tests';
import './editor/Viewport.tests';
import './editor/Viewport.Info.tests';
//editor/commands
import './editor/commands/AddObjectCommand.tests';
import './editor/commands/AddScriptCommand.tests';
import './editor/commands/MoveObjectCommand.tests';
import './editor/commands/MultiCmdsCommand.tests';
import './editor/commands/RemoveObjectCommand.tests';
import './editor/commands/RemoveScriptCommand.tests';
import './editor/commands/SetColorCommand.tests';
import './editor/commands/SetGeometryCommand.tests';
import './editor/commands/SetGeometryValueCommand.tests';
import './editor/commands/SetMaterialColorCommand.tests';
import './editor/commands/SetMaterialCommand.tests';
import './editor/commands/SetMaterialMapCommand.tests';
import './editor/commands/SetMaterialValueCommand.tests';
import './editor/commands/SetPositionCommand.tests';
import './editor/commands/SetRotationCommand.tests';
import './editor/commands/SetScaleCommand.tests';
import './editor/commands/SetSceneCommand.tests';
import './editor/commands/SetScriptValueCommand.tests';
import './editor/commands/SetUuidCommand.tests';
import './editor/commands/SetValueCommand.tests';
//editor/others
/**
* @author TristanVALCKE / https://github.com/Itee
*/
import './qunit-utils.js';
import './example/utils/BufferGeometryUtils.tests';
import './example/exporters/GLTFExporter.tests';
import './example/loaders/GLTFLoader.tests';
import './example/objects/Lensflare.tests';
/**
* @author TristanVALCKE / https://github.com/Itee
*/
import './qunit-utils.js';
//src
import './src/constants.tests';
import './src/polyfills.tests';
import './src/utils.tests';
//src/animation
import './src/animation/AnimationAction.tests';
import './src/animation/AnimationClip.tests';
import './src/animation/AnimationMixer.tests';
import './src/animation/AnimationObjectGroup.tests';
import './src/animation/AnimationUtils.tests';
import './src/animation/KeyframeTrack.tests';
import './src/animation/PropertyBinding.tests';
import './src/animation/PropertyMixer.tests';
//src/animation/tracks
import './src/animation/tracks/BooleanKeyframeTrack.tests';
import './src/animation/tracks/ColorKeyframeTrack.tests';
import './src/animation/tracks/NumberKeyframeTrack.tests';
import './src/animation/tracks/QuaternionKeyframeTrack.tests';
import './src/animation/tracks/StringKeyframeTrack.tests';
import './src/animation/tracks/VectorKeyframeTrack.tests';
//src/audio
import './src/audio/Audio.tests';
import './src/audio/AudioAnalyser.tests';
import './src/audio/AudioContext.tests';
import './src/audio/AudioListener.tests';
import './src/audio/PositionalAudio.tests';
//src/cameras
import './src/cameras/ArrayCamera.tests';
import './src/cameras/Camera.tests';
import './src/cameras/CubeCamera.tests';
import './src/cameras/OrthographicCamera.tests';
import './src/cameras/PerspectiveCamera.tests';
import './src/cameras/StereoCamera.tests';
//src/core
import './src/core/BufferAttribute.tests';
import './src/core/BufferGeometry.tests';
import './src/core/Clock.tests';
import './src/core/DirectGeometry.tests';
import './src/core/EventDispatcher.tests';
import './src/core/Face3.tests';
import './src/core/Geometry.tests';
import './src/core/InstancedBufferAttribute.tests';
import './src/core/InstancedBufferGeometry.tests';
import './src/core/InstancedInterleavedBuffer.tests';
import './src/core/InterleavedBuffer.tests';
import './src/core/InterleavedBufferAttribute.tests';
import './src/core/Layers.tests';
import './src/core/Object3D.tests';
import './src/core/Raycaster.tests';
import './src/core/Uniform.tests';
//src/extras
import './src/extras/ShapeUtils.tests';
//src/extras/core
import './src/extras/core/Curve.tests';
import './src/extras/core/CurvePath.tests';
import './src/extras/core/Font.tests';
import './src/extras/core/Interpolations.tests';
import './src/extras/core/Path.tests';
import './src/extras/core/Shape.tests';
import './src/extras/core/ShapePath.tests';
//src/extras/curves
import './src/extras/curves/ArcCurve.tests';
import './src/extras/curves/CatmullRomCurve3.tests';
import './src/extras/curves/CubicBezierCurve.tests';
import './src/extras/curves/CubicBezierCurve3.tests';
import './src/extras/curves/EllipseCurve.tests';
import './src/extras/curves/LineCurve.tests';
import './src/extras/curves/LineCurve3.tests';
import './src/extras/curves/QuadraticBezierCurve.tests';
import './src/extras/curves/QuadraticBezierCurve3.tests';
import './src/extras/curves/SplineCurve.tests';
//src/extras/objects
import './src/extras/objects/ImmediateRenderObject.tests';
//src/geometries
import './src/geometries/BoxGeometry.tests';
import './src/geometries/CircleGeometry.tests';
import './src/geometries/ConeGeometry.tests';
import './src/geometries/CylinderGeometry.tests';
import './src/geometries/DodecahedronGeometry.tests';
import './src/geometries/EdgesGeometry.tests';
import './src/geometries/ExtrudeGeometry.tests';
import './src/geometries/IcosahedronGeometry.tests';
import './src/geometries/LatheGeometry.tests';
import './src/geometries/OctahedronGeometry.tests';
import './src/geometries/ParametricGeometry.tests';
import './src/geometries/PlaneGeometry.tests';
import './src/geometries/PolyhedronGeometry.tests';
import './src/geometries/RingGeometry.tests';
import './src/geometries/ShapeGeometry.tests';
import './src/geometries/SphereGeometry.tests';
import './src/geometries/TetrahedronGeometry.tests';
import './src/geometries/TextGeometry.tests';
import './src/geometries/TorusGeometry.tests';
import './src/geometries/TorusKnotGeometry.tests';
import './src/geometries/TubeGeometry.tests';
import './src/geometries/WireframeGeometry.tests';
//src/helpers
import './src/helpers/ArrowHelper.tests';
import './src/helpers/AxesHelper.tests';
import './src/helpers/Box3Helper.tests';
import './src/helpers/BoxHelper.tests';
import './src/helpers/CameraHelper.tests';
import './src/helpers/DirectionalLightHelper.tests';
import './src/helpers/GridHelper.tests';
import './src/helpers/HemisphereLightHelper.tests';
import './src/helpers/PlaneHelper.tests';
import './src/helpers/PointLightHelper.tests';
import './src/helpers/PolarGridHelper.tests';
import './src/helpers/SkeletonHelper.tests';
import './src/helpers/SpotLightHelper.tests';
//src/lights
import './src/lights/AmbientLight.tests';
import './src/lights/DirectionalLight.tests';
import './src/lights/DirectionalLightShadow.tests';
import './src/lights/HemisphereLight.tests';
import './src/lights/Light.tests';
import './src/lights/LightShadow.tests';
import './src/lights/PointLight.tests';
import './src/lights/RectAreaLight.tests';
import './src/lights/SpotLight.tests';
import './src/lights/SpotLightShadow.tests';
//src/loaders
import './src/loaders/AnimationLoader.tests';
import './src/loaders/AudioLoader.tests';
import './src/loaders/BufferGeometryLoader.tests';
import './src/loaders/Cache.tests';
import './src/loaders/CompressedTextureLoader.tests';
import './src/loaders/CubeTextureLoader.tests';
import './src/loaders/DataTextureLoader.tests';
import './src/loaders/FileLoader.tests';
import './src/loaders/FontLoader.tests';
import './src/loaders/ImageLoader.tests';
import './src/loaders/Loader.tests';
import './src/loaders/LoaderUtils.tests';
import './src/loaders/LoadingManager.tests';
import './src/loaders/MaterialLoader.tests';
import './src/loaders/ObjectLoader.tests';
import './src/loaders/TextureLoader.tests';
//src/materials
import './src/materials/LineBasicMaterial.tests';
import './src/materials/LineDashedMaterial.tests';
import './src/materials/Material.tests';
import './src/materials/MeshBasicMaterial.tests';
import './src/materials/MeshDepthMaterial.tests';
import './src/materials/MeshDistanceMaterial.tests';
import './src/materials/MeshLambertMaterial.tests';
import './src/materials/MeshNormalMaterial.tests';
import './src/materials/MeshPhongMaterial.tests';
import './src/materials/MeshPhysicalMaterial.tests';
import './src/materials/MeshStandardMaterial.tests';
import './src/materials/MeshToonMaterial.tests';
import './src/materials/PointsMaterial.tests';
import './src/materials/RawShaderMaterial.tests';
import './src/materials/ShaderMaterial.tests';
import './src/materials/ShadowMaterial.tests';
import './src/materials/SpriteMaterial.tests';
//src/math
import './src/math/Box2.tests';
import './src/math/Box3.tests';
import './src/math/Color.tests';
import './src/math/Cylindrical.tests';
import './src/math/Euler.tests';
import './src/math/Frustum.tests';
import './src/math/Interpolant.tests';
import './src/math/Line3.tests';
import './src/math/MathUtils.tests';
import './src/math/Matrix3.tests';
import './src/math/Matrix4.tests';
import './src/math/Plane.tests';
import './src/math/Quaternion.tests';
import './src/math/Ray.tests';
import './src/math/Sphere.tests';
import './src/math/Spherical.tests';
import './src/math/Triangle.tests';
import './src/math/Vector2.tests';
import './src/math/Vector3.tests';
import './src/math/Vector4.tests';
//src/math/interpolants
import './src/math/interpolants/CubicInterpolant.tests';
import './src/math/interpolants/DiscreteInterpolant.tests';
import './src/math/interpolants/LinearInterpolant.tests';
import './src/math/interpolants/QuaternionLinearInterpolant.tests';
//src/objects
import './src/objects/Bone.tests';
import './src/objects/Group.tests';
import './src/objects/Line.tests';
import './src/objects/LineLoop.tests';
import './src/objects/LineSegments.tests';
import './src/objects/LOD.tests';
import './src/objects/Mesh.tests';
import './src/objects/Points.tests';
import './src/objects/Skeleton.tests';
import './src/objects/SkinnedMesh.tests';
import './src/objects/Sprite.tests';
//src/renderers
import './src/renderers/WebGLRenderer.tests';
import './src/renderers/WebGLRenderTarget.tests';
import './src/renderers/WebGLCubeRenderTarget.tests';
//src/renderers/shaders
import './src/renderers/shaders/ShaderChunk.tests';
import './src/renderers/shaders/ShaderLib.tests';
import './src/renderers/shaders/UniformsLib.tests';
import './src/renderers/shaders/UniformsUtils.tests';
//src/renderers/webgl
import './src/renderers/webgl/WebGLAttributes.tests';
import './src/renderers/webgl/WebGLBackground.tests';
import './src/renderers/webgl/WebGLBufferRenderer.tests';
import './src/renderers/webgl/WebGLCapabilities.tests';
import './src/renderers/webgl/WebGLClipping.tests';
import './src/renderers/webgl/WebGLExtensions.tests';
import './src/renderers/webgl/WebGLGeometries.tests';
import './src/renderers/webgl/WebGLIndexedBufferRenderer.tests';
import './src/renderers/webgl/WebGLLights.tests';
import './src/renderers/webgl/WebGLMorphtargets.tests';
import './src/renderers/webgl/WebGLObjects.tests';
import './src/renderers/webgl/WebGLProgram.tests';
import './src/renderers/webgl/WebGLPrograms.tests';
import './src/renderers/webgl/WebGLProperties.tests';
import './src/renderers/webgl/WebGLRenderLists.tests';
import './src/renderers/webgl/WebGLShader.tests';
import './src/renderers/webgl/WebGLShadowMap.tests';
import './src/renderers/webgl/WebGLState.tests';
import './src/renderers/webgl/WebGLTextures.tests';
import './src/renderers/webgl/WebGLUniforms.tests';
import './src/renderers/webgl/WebGLUtils.tests';
//src/scenes
import './src/scenes/Fog.tests';
import './src/scenes/FogExp2.tests';
import './src/scenes/Scene.tests';
//src/textures
import './src/textures/CanvasTexture.tests';
import './src/textures/CompressedTexture.tests';
import './src/textures/CubeTexture.tests';
import './src/textures/DataTexture.tests';
import './src/textures/DepthTexture.tests';
import './src/textures/Texture.tests';
import './src/textures/VideoTexture.tests';
......@@ -3,14 +3,14 @@
<head>
<meta charset="utf-8">
<title>ThreeJS Unit Tests - Using Files in /editor</title>
<link rel="stylesheet" href="../../node_modules/qunit/qunit/qunit.css">
<link rel="stylesheet" href="../node_modules/qunit/qunit/qunit.css">
</head>
<body>
<div id="qunit"></div>
<div id="qunit-fixture"></div>
<script src="../../node_modules/qunit/qunit/qunit.js"></script>
<script src="../node_modules/qunit/qunit/qunit.js"></script>
<script src="qunit-utils.js"></script>
<script src="SmartComparer.js"></script>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册