joshmarinacci / voxeljs-next

The next generation of Voxel JS
https://vr.josh.earth/voxeljs-next/examples/ecsy.html
BSD 3-Clause "New" or "Revised" License
147 stars 20 forks source link

improvement: unit testing #32

Open drBenway opened 5 years ago

drBenway commented 5 years ago

Would be nice if the repo has unit tests. It helps contributers in better understanding/extending the code. expl for jest: npm install --save-dev jest Jest doesn't understand es6 imports so adding a bablerc file with

{
  "env": {
    "test": {
      "plugins": ["transform-es2015-modules-commonjs"]
    }
  }
}

and install the transform plugin npm install --save-dev babel-plugin-transform-es2015-modules-commonjs