Binari icon indicating copy to clipboard operation
Binari copied to clipboard

Create Code Verification

Open BrandonArmand opened this issue 5 years ago • 0 comments

  • [ ] Bug
  • [ ] Clean up
  • [ ] Question
  • [x] Enhancement
  • [ ] Suggestion
  • [ ] Other

What needs to be done.

We need to add a way to verify that the user's code meets the lessons demands. Lessons like 'Insertion' should check that that the Node.insert() method works as it should.

Why

This is the final step of the MVP. Once completed, v1.0 should be just about ready. This will allow users to know that their code works correctly and provide a way to move seamlessly from on lesson to another.

How

We already have manual checks in Binari\src\views\Playground\Playground.js where this code snippet is found:

    BinaryTree.insert(25)
    BinaryTree.insert(15)
    BinaryTree.insert(35)
    BinaryTree.insert(75)
    BinaryTree.insert(85)
    BinaryTree.insert(65)
  1. We need to move this into the lesson folder, probably into a new tests.js file where we will contain every check for each individual lesson.

  2. Then figure out the best way to incorporate the checks inside the playground file.

  3. Lastly, a way to un-intrusively display that the check failed/passed needs to be added since the user will want to see the binary tree at all times.

Notes

This will be a lot of work, so separate small commits may be the best way to go about working on this.

BrandonArmand avatar Jan 23 '20 18:01 BrandonArmand