Specs & Test Cases/Build and validate your own

Specifications & Test Cases

Want to build it yourself? I can provide the specifications and test cases needed to build a margin/risk engine in your own stack and validate that it's right.

  1. 01Requirements

    Margin rules and common broker needs, written out.

  2. 02Data model

    How positions, orders, rates and results are structured.

  3. 03Test cases

    Curated JSON test cases: inputs, expected result, and descriptions.

How you use them

  • Build your engine from the requirements and the data model
  • Run the test cases through it
  • Compare your results with the expected results, case by case

Each case gives the inputs and the expected result.

This is one of the test cases, as delivered. Switch to JSON to see the file itself.

Let's talk.

Building your own margin & risk engine? Tell me about your next project or current implementation.