david-yz-liu / memory-viz

Javascript library for creating beginner-friendly memory model diagrams.
https://www.cs.toronto.edu/~david/memory-viz/demo/
2 stars 7 forks source link

Update test setup and add instructions to README #29

Closed david-yz-liu closed 5 months ago

david-yz-liu commented 5 months ago

Proposed Changes

(Describe your changes here. Also describe the motivation for your changes: what problem do they solve, or how do they improve the application or codebase? If this pull request fixes an open issue, use a keyword to link this pull request to the issue.)

The memory-viz test suite wasn't running properly because the configuration for moduleNameMapper introduced in #15 wasn't working on the roughjs/bundled/rough.esm.js import. So I've modified the import to just use roughjs (with an appropriate alias in the webpack configuration), and updated the demo website to import from the package, which will use the built file.

This change also seems to have allowed Typescript to detect types from the roughjs library, and so I fixed a small type error in passing the seed option to the library's svg function.

I also added instructions on running the tests to the README.

Screenshots of your changes (if applicable)

Type of Change

(Write an X or a brief description next to the type or types that best describe your changes.)

Type Applies?
🚨 Breaking change (fix or feature that would cause existing functionality to change)
✨ New feature (non-breaking change that adds functionality)
πŸ› Bug fix (non-breaking change that fixes an issue)
🎨 User interface change (change to user interface; provide screenshots)
♻️ Refactoring (internal change to codebase, without changing functionality)
🚦 Test update (change that only adds or modifies tests) x
πŸ“š Documentation update (change that only updates documentation)
πŸ“¦ Dependency update (change that updates a dependency)
πŸ”§ Internal (change that only affects developers or continuous integration)

Checklist

(Complete each of the following items for your pull request. Indicate that you have completed an item by changing the [ ] into a [x] in the raw text, or by clicking on the checkbox in the rendered description on GitHub.)

Before opening your pull request:

After opening your pull request:

Questions and Comments

(Include any questions or comments you have regarding your changes.)

coveralls commented 5 months ago

Pull Request Test Coverage Report for Build 9048695477

Details


Totals Coverage Status
Change from base Build 8933386791: 0.0%
Covered Lines: 272
Relevant Lines: 423

πŸ’› - Coveralls