MCPcopy
hub / github.com/4ian/GDevelop / checkProgress

Function checkProgress

Extensions/TweenBehavior/tests/LegacyTweenBehavior.spec.js:190–202  ·  view source on GitHub ↗
(steps, getValueFunctions)

Source from the content-addressed store, hash-verified

188 });
189
190 const checkProgress = (steps, getValueFunctions) => {
191 if (!Array.isArray(getValueFunctions)) {
192 getValueFunctions = [getValueFunctions];
193 }
194 for (let i = 0; i < steps; i++) {
195 const oldValues = getValueFunctions.map((getValue) => getValue());
196 runtimeScene.renderAndStep(1000 / 60);
197
198 for (let index = 0; index < oldValues.length; index++) {
199 expect(getValueFunctions[index]()).not.to.be(oldValues[index]);
200 }
201 }
202 };
203
204 it('can tween an object variable', () => {
205 const variable = object.getVariables().get('MyVariable');

Callers 1

Calls 3

renderAndStepMethod · 0.80
getValueFunction · 0.50
mapMethod · 0.45

Tested by

no test coverage detected