From ca62b8de9fa881e786b35040cf6058e9e23e7cc2 Mon Sep 17 00:00:00 2001 From: Par Winzell Date: Mon, 10 Dec 2018 10:54:39 -0800 Subject: [PATCH] ... do that the way I intended. --- npm/tests/test/fbx2gltf.ts | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/npm/tests/test/fbx2gltf.ts b/npm/tests/test/fbx2gltf.ts index 24bba8a..b3539c1 100644 --- a/npm/tests/test/fbx2gltf.ts +++ b/npm/tests/test/fbx2gltf.ts @@ -7,11 +7,15 @@ import { validateBytes } from 'gltf-validator'; interface Model { path: string; + ignoredIssues?: Array; } const MODELS :Array = [ { path: 'fromFacebook/Jon/jon_morph' }, - { path: 'fromFacebook/Jon/troll-final' }, + { + path: 'fromFacebook/Jon/troll-final', + ignoredIssues: [ 'ACCESSOR_NON_UNIT' ], + }, { path: 'fromFacebook/Natalie/GlitchRobot' }, { path: 'fromFacebook/Ocean/blackvan/blackvan_with_windows' }, { path: 'fromFacebook/Ocean/zell_van_vertex_color' }, @@ -49,11 +53,11 @@ describe('FBX2glTF', () => { it('resulting glb should be valid', async() => { try { - const report = await validateBytes( - glbBytes, { - ignoredIssues: [ 'ACCESSOR_NON_UNIT' ], - }, - ); + let options = {}; + if (model.ignoredIssues) { + options.ignoredIssues = model.ignoredIssues; + } + const report = await validateBytes(glbBytes, options); expect(report.issues.numErrors).to.equal(0); expect(report.issues.numWarnings).to.equal(0);