V3.6.0 add particle material test case (#11597)

* add particle material test case

* add game stop
This commit is contained in:
zxx43
2022-06-18 14:10:07 +08:00
committed by GitHub
parent fb9c4a9ee4
commit 766d086fbb
+16
View File
@@ -0,0 +1,16 @@
import { director, Node, Scene } from "../../cocos/core";
import { legacyCC } from "../../cocos/core/global-exports";
import { ParticleSystem } from "../../exports/particle";
test('particle system material test', function () {
const scene = new Scene('test');
director.runSceneImmediate(scene);
const temp0 = new Node();
scene.addChild(temp0);
const particle = temp0.addComponent(ParticleSystem) as ParticleSystem;
expect(particle.sharedMaterials).toBeDefined();
legacyCC.game.step();
});