Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Rhum for Testing #68

Closed
shadowtime2000 opened this issue Dec 23, 2020 · 3 comments
Closed

Use Rhum for Testing #68

shadowtime2000 opened this issue Dec 23, 2020 · 3 comments
Milestone

Comments

@shadowtime2000
Copy link
Member

Rhum is a testing framework built on top of Deno.test created by the team behind the Drash REST API framework. This is only necessary when we have more tests, so I am marking it as future for now.

Refs:

  1. Documentation site for Rhum
  2. v2 issue for Rhum (drashland/rhum#75)
@shadowtime2000 shadowtime2000 added this to the future milestone Dec 23, 2020
@ije
Copy link
Member

ije commented Dec 24, 2020

centainly we need full testings! what different between rhum and Deno.test? why we should use it?

@shadowtime2000
Copy link
Member Author

@ije rhum allows us to more easily organize and compose our tests. Here is part of the example they give on the front page:

// 1. Define your test plan (usually the test file's name)
// 2. Define your test suites (usually methods being tested)
// 3. Define your test cases with assertions
Rhum.testPlan("app_test.ts", () => {
  Rhum.testSuite("run()", () => {
    Rhum.testCase("Returns true", () => {
      const result = run();
      Rhum.asserts.assertEquals(true, result);
    });
  });
  Rhum.testSuite("close()", () => {
    Rhum.testCase("Returns true", async () => {
      const result = await close();
      Rhum.asserts.assertEquals(true, result);
    });
  });
});

idk how much code we have but i think we have like 5k so i think it would be best to organize our tests like that.

@ije
Copy link
Member

ije commented Jan 22, 2021

Rhum is cool, but i think deno.test is enough, let's keep the testings as simple as possible.

@ije ije closed this as completed Jan 22, 2021
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

No branches or pull requests

2 participants