mix rfc7208.testsuite (Spfcheck v0.10.0) View Source
This mix task reads
./priv/rfc7208-tests.yaml
(the rfc7208 testsuite) and creates:
./test/rfc7208-<xx>-<desc>.exs, along with./test/zones/rfc7208-<xx>-<desc>.zonedata
for each section (see below) in the testsuite.
Tests
Tests check the verdict and explanation string for each testcase in the
testsuite. They also include a _cli = """spfcheck ...""" which can be
copied to the command line to see the same testcase with debug output in the
terminal.
Each test is also tagged with:
set: "section_number", andtst: "section_number.test_number"
so mix test --only .. can focus on a complete section or just one specific
test.
Usage:
mix rfc7208.testsuite
mix test
mix test --only set:x, where x is in 0..15
mix test --only tst:x.y, where y refers to a specific test in section xMore information at www.open-spf.org:
RFC7208 testsuite sections
- 0 - Initial processing
- 1 - Record lookup
- 2 - Selecting records
- 3 - Record evaluation
- 4 -
ALLmechanism syntax - 5 -
PTRmechanism syntax - 6 -
Amechanism syntax - 7 -
INCLUDEmechanism syntax - 8 -
MXmechanism syntax - 9 -
EXISTSmechanism syntax - 10 -
IP4mechanism syntax - 11 -
IP6mechanism syntax - 12 - Semantics of
EXPand other modifiers - 13 - Macro expansion rules
- 14 - Processing limits
- 15 - Test cases from implementation bugs