xml3d / xml3d.js

The WebGL/JS implementation of XML3D
Other
75 stars 25 forks source link

Xflow WebCL Unit Tests #55

Closed K1ll3rF0x closed 9 years ago

K1ll3rF0x commented 10 years ago

This pull requests includes some unit tests for testing the new WebCL operator and the platform attribute.

Additionally, one smaller feature is included: the platform selection logic now actually takes the "platform"-attribute in account when selecting a platform. This was unintentionally left out from the previous pull requests.

K1ll3rF0x commented 9 years ago

@ksons et al. Could you merge this, so we can more easily submit a new pull request regarding to WebCL API fixes that @jmietola is working on.

ksons commented 9 years ago

I merged, build and run the test and everything seems to be okay except three tests that fail due: Xflow tests: Operator - Platform fallback (in /tests/data-xflow.js): QUnit.config.semaphore was 0 already

This is probably due to a new version of qunit that has stricter testing for correct use of the semaphores (some of our own tests failed after updateing for the same reason).

Cpuld you fix this? I'll merge your code then.

jmietola commented 9 years ago

Is there default timeout set somewhere(QUnit.config)? When I run test at first it fails but second time it passes. After I clear the cache it fails again.

ksons commented 9 years ago

The timeout for tests is 5sec. However, in most cases the asychronous loading of resource makes troubles. We have some new events, event semantics (loaded event triggers only after frist rendering) and flags (XML3DElement::complete) to handle this better. Additionally we started using prmises to describe the order of execution better: https://github.com/xml3d/xml3d.js/blob/develop/tests/extrefcombined.js#L80

K1ll3rF0x commented 9 years ago

Ok, it seems that making handling the tests better seems to require a bit of research, which at this point is not fitting well to our timetables.

Could we do the following: Merge this pull request, so @jmietola can submit his pull request containing the webcl API + xflow webcl operator fixes to make the WebCL features working again ASAP and ready to be used by the 3rd party developers. After that, we can fine tune the WebCL related test cases in a more relaxed manner.

ksons commented 9 years ago

I just noticed that it is an timing issue now already. Sure, I will merge it.

Please be aware that we switched to a new build system on the development branch (grunt). We want to incrementally move to a better dependeny managment. This might require some changes. Please contact me if you need help.