Annotations and tests should find each other when searching
Opened this issue · 0 comments
seebees commented
Given an annotation in code like this
//= master_key_spec.txt#2.1
//# On initialization, the caller MUST provide:
//# * An AWS KMS key identifier
//# * An AWS KMS SDK client
Currently the test looks like this
//= master_key_spec.txt#2.1
//= type=test
//# On initialization, the caller MUST provide:
//# * An AWS KMS key identifier
//# * An AWS KMS SDK client
However, this means when searching for the test from the code
or the code from the test using a simple search,
the //= type=test
line needs to be added or removed.
I suggest changing this to place the optional type
at the end of the annotation.
Like this
//= master_key_spec.txt#2.1
//# On initialization, the caller MUST provide:
//# * An AWS KMS key identifier
//# * An AWS KMS SDK client
//= type=test
Another option would be to append the requirement number to spec reference.
So this would be the 5th requirement in the section:
//= master_key_spec.txt#2.1&n=5