Context

Contexts wrap a set of tests against the functionality under a specific state. This can be a specific function or subject.


context(char* context)

The context construct takes in the current context descriptor char* context and groups a set of tests in its output.


Output

describe My Test Suite:
  context .add_two_ints
    it returns the sum of two numbers
      ...

Example


#include "awry/awry.h"

describe("context construct", test_context_construct)
  context("definition")
    it("is defined")
      expect(CONTEXT_TYPE) to equal(0x03)
    end
  end
end

int main(void) {
  Awry.run();
  Awry.clear(&Awry);
  return 0;
}