FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Webxr unit tests by diarmidmackenzie · Pull Request #5227 · aframevr/aframe · GitHub

Webxr unit tests - #5227

Merged
dmarcos merged 3 commits into
aframevr:masterfrom
diarmidmackenzie:webxr-unit-tests
Feb 6, 2023
Merged

Webxr unit tests#5227
dmarcos merged 3 commits into
aframevr:masterfrom
diarmidmackenzie:webxr-unit-tests

Conversation

diarmidmackenzie commented Feb 1, 2023
edited
Loading

Copy link
Copy Markdown
Contributor

Description:

As noted in #5217, and one reason that bug #5221 slipped through - the Enter / Exit VR tests for a-scene are still entirely focussed on WebVR rather than WebXR.

This PR adds some tests for WebXR

Changes proposed:

I approached this as follows;

  • Duplicate the existing WebVR tests
  • Add additional stubbing code etc. to make them work
  • Remove the tests that seem not to be relevant (some tests depend on events like vrdisplaypointerrestricted and vrdisplaypresentchange that seem to be WebVR only).

I doubt this gives us perfect coverage of WebXR, but it should give good coverage of a broad range of key scenarios around entry to / exit from VR.

I have also confirmed that this set of tests would have caught the bug fixed under #5221.

Some very minor changes to a-scene also made, to allow simulation of WebXR availability via the el.hasWebXR flag.

diarmidmackenzie marked this pull request as ready for review February 1, 2023 20:47
Comment thread tests/__init.test.js Outdated
getDevice: function () { return {requestPresent: function () {}}; },
isPresenting: function () { return true; },
setDevice: function () {},
setSession: function () {

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

can do one liner

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

fixed

dmarcos commented Feb 6, 2023

Copy link
Copy Markdown
Member

Thank you very much!

dmarcos merged commit d49ddaa into aframevr:master Feb 6, 2023
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants


Back | FazBrowse Home | New Git URL