Skip to content

Add code coverage #6

Open
Open
@agilgur5

Description

@agilgur5

Now that #5 adds a test harness, runner, and some tests, it should be simple to just add some code coverage. It'll have to be customized a bit to ignore mostly vendored code, i.e. physi.js, physijs_worker.js, and ammo.js (though there's not much code left after that 😅 ). Here's how to exclude/include with nyc.

I just started looking into it and realized a pretty big problem -- the tests import the bundled code, not the source code, so without some likely quite hacky source mapping, it's probably not possible to actually get coverage numbers for source code.
But the non-vendored code basically doesn't branch and is quite tiny, so nbd either way in all honesty.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions