Advanced usage

Now, when you are already familiar with CodeBud basic concepts, you've might noticed that CodeBud is very configurable and can be personalized for many type of tasks.

Of course, this is only yours decision how you're going to use CodeBud. You can use it only for sending complex scenarios, or only for redux state observing. But here is some ideas that you might find interesting.

Integration with already existing tests

For example, you have some project and there are some unit test you've written. How does app tester start this test? It can be done with CodeBud: just wrap your tests with instruction handler, wait for results and return them.

const INSTRUCTIONS: Instruction[] = [
  // ...
  {
    id: "runUnitTests",
    description: "Run our prepared unit tests and the result",
    handler: async () => {
      // Call your tests function and wait for the result
      const result = await runUnitTests();

      // Return result
      return {res: result.ok ? "TESTS PASSED" : "TESTS FAILED"};
    }
  },
];
// ...

Was this page helpful?