<?xml version="1.0" encoding="utf-8"?>
<!-- name="GENERATOR" content="github.com/mmarkdown/mmark Mmark Markdown Processor - mmark.miek.nl" -->
<rfc version="3" ipr="trust200902" docName="draft-hopkins-evp-spec-01" submissionType="independent" category="info" xml:lang="en" xmlns:xi="http://www.w3.org/2001/XInclude" indexInclude="true">

<front>
<title abbrev="evp-spec">Evidence Package Format Specification</title><seriesInfo value="draft-hopkins-evp-spec-01" stream="independent" status="informational" name="Internet-Draft"></seriesInfo>
<author initials="L." surname="Hopkins" fullname="Lily Hopkins"><organization></organization><address><postal><street></street>
</postal><email>lily@hpkns.uk</email>
<uri>https://github.com/lilopkins</uri>
</address></author><author surname="Turner" fullname="Eden Turner"><organization></organization><address><postal><street></street>
</postal><email>somebirb7190@gmail.com</email>
<uri>https://github.com/Some-Birb7190</uri>
</address></author><date/>
<area></area>
<workgroup></workgroup>
<keyword>evp</keyword>
<keyword>evidence</keyword>
<keyword>format</keyword>
<keyword>specification</keyword>

<abstract>
<t>Taking evidence is a key part of any software testing process. This
specification defines a format which collects evidence together and
stores metadata and annotations in an organised fashion from both manual
and automated testing sources.</t>
</abstract>

</front>

<middle>

<section anchor="introduction"><name>Introduction</name>

<section anchor="purpose"><name>Purpose</name>
<t>The purpose of this specification is to define a format for storage of
test evidence that:</t>

<ul spacing="compact">
<li>allows for basic collation of evidence;</li>
<li>can store any kind of file type that might be produced;</li>
<li>stores data compressed;</li>
<li>stores related evidence together, but allows for dividing up by test
case, and;</li>
<li>is built upon widely available standards.</li>
</ul>
<t>The format does not attempt to:</t>

<ul spacing="compact">
<li>act as an captioned archiving solution for other purposes, even if it
may be suitable for them.</li>
</ul>
</section>

<section anchor="intended-audience"><name>Intended Audience</name>
<t>This specification is intended for those who might wish to write their
own implementation of the evidence package format.</t>
</section>

<section anchor="changes-from-previous-verisons"><name>Changes from Previous Verisons</name>
<t>This document forms the original specification.</t>
</section>
</section>

<section anchor="terminology"><name>Terminology</name>
<t>The key words &quot;<bcp14>MUST</bcp14>&quot;, &quot;<bcp14>MUST NOT</bcp14>&quot;, &quot;<bcp14>REQUIRED</bcp14>&quot;, &quot;<bcp14>SHALL</bcp14>&quot;,
&quot;<bcp14>SHALL NOT</bcp14>&quot;, &quot;<bcp14>SHOULD</bcp14>&quot;, &quot;<bcp14>SHOULD NOT</bcp14>&quot;, &quot;<bcp14>RECOMMENDED</bcp14>&quot;,
&quot;<bcp14>NOT RECOMMENDED</bcp14>&quot;, &quot;<bcp14>MAY</bcp14>&quot;, and &quot;<bcp14>OPTIONAL</bcp14>&quot; in this document
are to be interpreted as described in BCP 14 <xref target="RFC2119"></xref> <xref target="RFC8174"></xref>
when, and only when, they appear in all capitals, as shown here.</t>
</section>

<section anchor="specification"><name>Specification</name>
<t>An evidence package is a structured ZIP archive. It <bcp14>MUST</bcp14> contain the
file &quot;manifest.json&quot;, and the directories &quot;media&quot; and &quot;testcases&quot;.</t>
<t>See <xref target="example-archive"></xref> for an example of the file's internal structure.</t>

<section anchor="manifest-json-file"><name>&quot;manifest.json&quot; File</name>
<t>The manifest.json file defines metadata relating to the entire package
of evidence. It <bcp14>MUST</bcp14> be a JSON <xref target="RFC8259"></xref> file with the following
elements:</t>
<table>
<thead>
<tr>
<th>Element</th>
<th>Condition</th>
<th>Type</th>
<th>Section</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>$schema</td>
<td>Optional</td>
<td>String</td>
<td></td>
<td>The $schema element <bcp14>MAY</bcp14> point to a copy of the schema for the manifest.</td>
</tr>

<tr>
<td>metadata</td>
<td>Mandatory</td>
<td>Object</td>
<td><xref target="manifest-metadata"></xref></td>
<td>The metadata element stores package metadata.</td>
</tr>

<tr>
<td>custom_test_case_metadata</td>
<td>Mandatory</td>
<td>Object</td>
<td><xref target="manifest-custom-metadata"></xref></td>
<td>Custom metadata fields for test cases in this package.</td>
</tr>

<tr>
<td>media</td>
<td>Mandatory</td>
<td>Array</td>
<td><xref target="manifest-media"></xref></td>
<td>The media element stores a list of media files that are stored in this evidence package.</td>
</tr>

<tr>
<td>test_cases</td>
<td>Mandatory</td>
<td>Array</td>
<td><xref target="manifest-test-cases"></xref></td>
<td>The test_cases element stores a list of test cases.</td>
</tr>
</tbody>
</table><t>See an example manifest.json file in <xref target="example-manifest"></xref>.</t>

<section anchor="manifest-metadata"><name>&quot;metadata&quot; Element</name>
<table>
<thead>
<tr>
<th>Element</th>
<th>Condition</th>
<th>Type</th>
<th>Section</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>title</td>
<td>Mandatory</td>
<td>String</td>
<td></td>
<td>The name of the evidence package.</td>
</tr>

<tr>
<td>authors</td>
<td>Mandatory</td>
<td>Array</td>
<td><xref target="manifest-metadata-authors"></xref></td>
<td>The authors attributed to this evidence package.</td>
</tr>
</tbody>
</table>
<section anchor="manifest-metadata-authors"><name>&quot;authors&quot; Array Element</name>
<table>
<thead>
<tr>
<th>Element</th>
<th>Condition</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>name</td>
<td>Mandatory</td>
<td>String</td>
<td>The author's name.</td>
</tr>

<tr>
<td>email</td>
<td>Optional</td>
<td>String/Null</td>
<td>The author's email address, although format is not verified.</td>
</tr>
</tbody>
</table></section>
</section>

<section anchor="manifest-custom-metadata"><name>&quot;custom_test_case_metadata&quot; Element</name>
<t>Elements within this object will become custom metadata properties for
test cases in this package. Each object <bcp14>MUST</bcp14> have the following
fields:</t>
<table>
<thead>
<tr>
<th>Element</th>
<th>Condition</th>
<th>Type</th>
<th>Section</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>name</td>
<td>Mandatory</td>
<td>String</td>
<td></td>
<td>The name of this custom metadata field.</td>
</tr>

<tr>
<td>description</td>
<td>Mandatory</td>
<td>String</td>
<td><xref target="manifest-metadata-authors"></xref></td>
<td>The description of this custom metadata field.</td>
</tr>

<tr>
<td>primary</td>
<td>Mandatory</td>
<td>Boolean</td>
<td><xref target="manifest-custom-metadata-primary"></xref></td>
<td>Is this custom field primary?</td>
</tr>
</tbody>
</table>
<section anchor="manifest-custom-metadata-primary"><name>&quot;primary&quot; Boolean</name>
<t>The &quot;primary&quot; value of custom metadata fields <bcp14>MAY</bcp14> be false for all
fields, or <bcp14>MAY</bcp14> be true for exactly one field. It <bcp14>MUST NOT</bcp14> be
true for more than one field.</t>
<t>The purpose of primary is not enforced as part of this specification,
however it should be seen as suggesting that one custom metadata field
is more useful than others, and as such may be used to influence the
information displayed to users, for example an implementor might choose
to show the primary custom metadata value for each test case alongside
it.</t>
</section>
</section>

<section anchor="manifest-media"><name>&quot;media&quot; Array Element</name>
<table>
<thead>
<tr>
<th>Element</th>
<th>Condition</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>sha256_checksum</td>
<td>Mandatory</td>
<td>String</td>
<td>The SHA256 checksum of the associated media file.</td>
</tr>

<tr>
<td>mime_type</td>
<td>Mandatory</td>
<td>String</td>
<td>The Internet Media Type <xref target="RFC2046"></xref> of the associated media file.</td>
</tr>
</tbody>
</table></section>

<section anchor="manifest-test-cases"><name>&quot;test_cases&quot; Array Element</name>
<table>
<thead>
<tr>
<th>Element</th>
<th>Condition</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>id</td>
<td>Mandatory</td>
<td>String</td>
<td>The UUID of the test case. If present here, there <bcp14>MUST</bcp14> be an associated test case file in the &quot;testcases&quot; directory of the package with the name &quot;&lt;UUID&gt;.json&quot;.</td>
</tr>
</tbody>
</table></section>
</section>

<section anchor="testcases-directory"><name>&quot;testcases&quot; Directory</name>
<t>The test cases directory stores the manifests for each test case within
this evidence package.</t>
<t>Each test case is stored as a JSON file, with a UUIDv4 name <xref target="RFC9562"></xref>.</t>

<section anchor="uuid-json-file"><name>&quot;&lt;uuid&gt;.json&quot; File</name>
<table>
<thead>
<tr>
<th>Element</th>
<th>Condition</th>
<th>Type</th>
<th>Section</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>$schema</td>
<td>Optional</td>
<td>String</td>
<td></td>
<td>The $schema element <bcp14>MAY</bcp14> point to a copy of the schema for the manifest.</td>
</tr>

<tr>
<td>metadata</td>
<td>Mandatory</td>
<td>Object</td>
<td><xref target="test-case-metadata"></xref></td>
<td>The metadata relating to this test case.</td>
</tr>

<tr>
<td>evidence</td>
<td>Mandatory</td>
<td>Array</td>
<td><xref target="test-case-evidence"></xref></td>
<td>The evidence within this test case.</td>
</tr>
</tbody>
</table><t>See an example &lt;uuid&gt;.json file in <xref target="example-test-case"></xref>.</t>

<section anchor="test-case-metadata"><name>&quot;metadata&quot; Element</name>
<table>
<thead>
<tr>
<th>Element</th>
<th>Condition</th>
<th>Type</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>title</td>
<td>Mandatory</td>
<td>String</td>
<td>The title of the test case.</td>
</tr>

<tr>
<td>execution_datetime</td>
<td>Mandatory</td>
<td>String</td>
<td>The ISO8601 date and time of the execution of this test case starting.</td>
</tr>

<tr>
<td>passed</td>
<td>Mandatory</td>
<td>String</td>
<td>The state of the test case, if present <bcp14>MUST</bcp14> be either &quot;pass&quot;, &quot;fail&quot;, or null. If absent, it <bcp14>MUST</bcp14> be interpreted as null.</td>
</tr>

<tr>
<td>custom</td>
<td>Mandatory</td>
<td>Object</td>
<td>Custom metadata values.</td>
</tr>
</tbody>
</table><t>The &quot;custom&quot; field is used to add custom metadata that has been
specified in the package manifest's &quot;custom_test_case_metadata&quot; field.
If a value is specified in &quot;custom&quot;, it <bcp14>MUST</bcp14> be present in the
package manifest, but all values in the package manifest do not need to
be present here. All values <bcp14>MUST</bcp14> be strings.</t>
</section>

<section anchor="test-case-evidence"><name>&quot;evidence&quot; Array Element</name>
<table>
<thead>
<tr>
<th>Element</th>
<th>Condition</th>
<th>Type</th>
<th>Section</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>kind</td>
<td>Mandatory</td>
<td>String</td>
<td><xref target="evidence-kind"></xref></td>
<td>The type of data stored.</td>
</tr>

<tr>
<td>value</td>
<td>Mandatory</td>
<td>String</td>
<td><xref target="evidence-value"></xref></td>
<td>The data stored within this piece of evidence.</td>
</tr>

<tr>
<td>caption</td>
<td>Optional</td>
<td>String/Null</td>
<td></td>
<td>An optional caption for this piece of evidence.</td>
</tr>

<tr>
<td>original_filename</td>
<td>Optional</td>
<td>String/Null</td>
<td></td>
<td>The original filename. <bcp14>MAY</bcp14> be provided for Image and File evidence, <bcp14>MUST NOT</bcp14> be provided otherwise.</td>
</tr>
</tbody>
</table>
<section anchor="evidence-kind"><name>&quot;kind&quot;</name>
<t>The &quot;kind&quot; of evidence <bcp14>MUST</bcp14> be one of &quot;Text&quot;, &quot;RichText&quot;, &quot;Image&quot;,
&quot;Http&quot;, &quot;File&quot;.</t>
<t>For more information about each type, see <xref target="kinds-of-evidence"></xref>.</t>
</section>

<section anchor="evidence-value"><name>&quot;value&quot;</name>
<t>The &quot;value&quot; <bcp14>MUST</bcp14> be one of the following acceptable patterns:</t>

<ul spacing="compact">
<li>&quot;plain:&quot; followed by plain text;</li>
<li>&quot;media:&quot; followed by a media file SHA256 hash, or;</li>
<li>&quot;base64:&quot; followed by a base64 string of data without padding.</li>
</ul>
</section>
</section>
</section>
</section>

<section anchor="media-directory"><name>&quot;media&quot; Directory</name>
<t>The &quot;media&quot; directory stores data in files within the ZIP archive that
would be otherwise impractical to store directly in the test cases.</t>
<t>Files stored in this directory are of abitrary type. They <bcp14>MUST</bcp14> be
named by their SHA256 checksum <xref target="RFC6234"></xref> with no extension. Their
SHA256 checksum and media type <bcp14>MUST</bcp14> be stored in the package
manifest &quot;media&quot; element.</t>
<t>In the unlikely event that there is a checksum clash, there is currently
no preferred method for resolving this. The probability of such a
situation is decided to be acceptably low given the expected size and
number of files stored in an evidence package, however implementors
<bcp14>MAY</bcp14> choose to store the clashing file as base64 data instead of as
an additional media file.</t>
</section>
</section>

<section anchor="handling-an-evidence-package"><name>Handling an Evidence Package</name>

<section anchor="locking"><name>Locking</name>
<t>When loading an evidence package, implemetors <bcp14>MUST</bcp14> use a lock file
with the file name &quot;.~lock.&quot; followed by the full name of the package it
protects, followed by &quot;#&quot;, for example for a package called
&quot;example.evp&quot;, the lock file <bcp14>MUST</bcp14> be called &quot;.~lock.example.evp#&quot;.
It <bcp14>MUST</bcp14> be located adjacent (in the same directory as) the evidence
package. The file <bcp14>MUST</bcp14> contain the process ID of the process holding
the lock.</t>
<t>The lock file should be considered as locking the package if it is
present, regardless of contents.</t>
<t>If either of these is not the case, it should be assumed that the there
is no current lock over the package.</t>
</section>

<section anchor="media-loading"><name>Media Loading</name>
<t>Software implementing the evidence package format <bcp14>MUST NOT</bcp14> load
files from the &quot;media&quot; directory into memory until it is needed for
display or for extraction. Implementors <bcp14>MUST</bcp14> use streams to load
media files to avoid trying to load the entire file into memory as it
may not fit.</t>
</section>
</section>

<section anchor="kinds-of-evidence"><name>Kinds of Evidence</name>
<t>Evidence packages support the following kinds of evidence:</t>
<table>
<thead>
<tr>
<th>Kind</th>
<th>Description</th>
</tr>
</thead>

<tbody>
<tr>
<td>&quot;Text&quot;</td>
<td>Plain text with no formatting.</td>
</tr>

<tr>
<td>&quot;RichText&quot;</td>
<td>Text with very basic markdown support.</td>
</tr>

<tr>
<td>&quot;Image&quot;</td>
<td>An image that should be rendered where possible.</td>
</tr>

<tr>
<td>&quot;Http&quot;</td>
<td>An HTTP request/response pair.</td>
</tr>

<tr>
<td>&quot;File&quot;</td>
<td>A raw file, which may be text or binary in nature.</td>
</tr>
</tbody>
</table><t>Implementors <bcp14>MUST</bcp14> support all of these kinds, and <bcp14>MUST NOT</bcp14>
introduce new kinds.</t>

<section anchor="richtext-s-markdown"><name>RichText's Markdown</name>
<t>The RichText evidence kind supports a very limited version of markdown:</t>

<ul spacing="compact">
<li>Headings 1-6</li>
<li>Bold, Italic, Monospace</li>
<li>Tables</li>
<li>Code blocks with syntax highlighting</li>
</ul>
<t>Implementors <bcp14>MUST NOT</bcp14> process any other markup.</t>
</section>

<section anchor="http-requests"><name>HTTP Requests</name>
<t>Where HTTP is used, a Record Separator character (0x1e) can be used to
split the request and response portion, for example the separator is
present at <em>1</em>:</t>

<sourcecode type="http">GET / HTTP/1.1
Host: example.com
User-Agent: HTTPie

\x1eHTTP/1.1 200 OK &lt;1&gt;
Cache-Control: max-age=1366
Connection: close
...
</sourcecode>
</section>
</section>

<section anchor="extending-behaviours-of-an-evidence-package"><name>Extending Behaviours of an Evidence Package</name>
<t>Every JSON file within an evidence package <bcp14>MAY</bcp14> have new fields
added, and as such extended behaviours <bcp14>MAY</bcp14> be implemented, however
implementors <bcp14>MUST</bcp14> be able to load an evidence package without these
additional fields.</t>
<t>When an implementor loads a file with fields it cannot understand, it
<bcp14>MUST</bcp14> retain the fields on saving the file.</t>
</section>

<section anchor="iana-considerations"><name>IANA Considerations</name>
<t>This document acts as the specification for the requested media type
application/vnd.angel.evidence-package.</t>
</section>

<section anchor="security-considerations"><name>Security Considerations</name>
<t>The evidence package format can store arbitrary files that may or may
not be executable. Implementors <bcp14>MUST NOT</bcp14> execute any file contained
within and <bcp14>SHALL</bcp14> only extract the contained files if needed.</t>
<t>Otherwise, there are no concerns for security from the file type itself.</t>
</section>

</middle>

<back>
<references><name>Normative References</name>
<xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.2046.xml"/>
<xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.2119.xml"/>
<xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.6234.xml"/>
<xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8174.xml"/>
<xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.8259.xml"/>
<xi:include href="https://bib.ietf.org/public/rfc/bibxml/reference.RFC.9562.xml"/>
</references>

<section anchor="example-archive"><name>Example Archive Layout</name>

<artwork><![CDATA[example.evp
 |- manifest.json
 |- media
 |   \- 203073da0b36a5921f2914e2093abcae7eb987846f405b438c25792bab1617fa
 \- testcases
     \- eabb5d31-a958-4609-ac98-83365e14d18b.json
]]></artwork>
</section>

<section anchor="example-manifest"><name>Example Package Manifest JSON</name>

<sourcecode type="json"><![CDATA[{
  "metadata": {
    "title": "Example Evidence Package",
    "authors": [
      {
        "name": "Anonymous Author"
      },
      {
        "name": "Lily Hopkins",
        "email": "lily@hpkns.uk"
      }
    ]
  },
  "custom_test_case_metadata": {
    "example": {
      "name": "Example Metadata Field",
      "description": "A field showing that custom fields can be added",
      "primary": true
    }
  },
  "media": [
    {
      "sha256_checksum": "203073da0b36a5921f2914e2093abcae7eb987846f405b438c25792bab1617fa",
      "mime_type": "text/plain"
    }
  ],
  "test_cases": [
    {
      "id": "eabb5d31-a958-4609-ac98-83365e14d18b"
    }
  ]
}
]]></sourcecode>
</section>

<section anchor="example-test-case"><name>Example Test Case Manifest JSON</name>

<sourcecode type="json"><![CDATA[{
  "metadata": {
    "title": "Example Test Case",
    "execution_datetime": "2025-05-01T11:13:29+01:00",
    "passed": null,
    "custom": {
      "example": "Example custom metadata field value"
    }
  },
  "evidence": [
    {
      "kind":"Text",
      "value":"plain:This is some text based evidence"
    },
    {
      "kind":"Text",
      "value":"base64:VGhpcyBpcyBzb21lIHRleHQgYmFzZWQgYmFzZTY0IGVuY29kZWQgZXZpZGVuY2U"
    },
    {
      "kind":"File",
      "value":"media:203073da0b36a5921f2914e2093abcae7eb987846f405b438c25792bab1617fa",
      "caption": "An example file",
      "original_filename": "example.txt"
    }
  ]
}
]]></sourcecode>
</section>

<section anchor="json-schema-for-package-manifest"><name>JSON Schema for Package Manifest</name>

<sourcecode type="json"><![CDATA[{
  "$id": "https://evidenceangel-schemas.hpkns.uk/manifest.2.schema.json",
  "$schema": "http://json-schema.org/draft-07/schema",
  "type": "object",
  "description": "The metadata file `metadata.json` as part of an evidence package.",
  "properties": {
    "metadata": {
      "type": "object",
      "properties": {
        "title": {
          "type": "string",
          "description": "The name of the evidence package.",
          "minLength": 1,
          "maxLength": 30
        },
        "authors": {
          "type": "array",
          "description": "The authors attributed to this evidence package.",
          "items": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "description": "The author's name."
              },
              "email": {
                "type": "string",
                "description": "The author's email address, although format is not verified."
              }
            },
            "required": ["name"]
          }
        },
        "description": {
          "type": "string",
          "description": "An optional description of the package."
        }
      },
      "required": ["title", "authors"]
    },
    "custom_test_case_metadata": {
      "type": "object",
      "description": "Custom metadata fields for test cases",
      "patternProperties": {
        ".+": {
          "type": "object",
          "description": "A custom metadata field",
          "properties": {
            "name": {
              "type": "string",
              "description": "A user-friendly name for this custom property."
            },
            "description": {
              "type": "string",
              "description": "A description for this custom property."
            },
            "primary": {
              "type": "boolean",
              "description": "Is this custom property the main one in this package? This may influence how it is displayed in editors."
            }
          },
          "required": ["name", "description", "primary"]
        }
      }
    },
    "media": {
      "type": "array",
      "items": {
        "type": "object",
        "description": "A media entry. When an entry is present in this manifest, it MUST also be present in the `media` directory of the package.",
        "properties": {
          "sha256_checksum": {
            "type": "string",
            "description": "The SHA256 checksum of the media file. This MUST also match identically the name of the file with no extension in the `media` directory.",
            "pattern": "^[0-9a-f]{64}$"
          },
          "mime_type": {
            "type": "string",
            "description": "The MIME type of the media file."
          }
        },
        "required": ["sha256_checksum", "mime_type"]
      }
    },
    "test_cases": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "format": "uuid",
            "description": "The UUID of the test case. If present here, there MUST be an associated test case file in the `testcases` directory of the package with the name `<UUID>.json`."
          }
        },
        "required": ["id"]
      }
    }
  },
  "required": ["metadata", "media", "test_cases"]
}
]]></sourcecode>
</section>

<section anchor="json-schema-for-test-case-manifest"><name>JSON Schema for Test Case Manifest</name>

<sourcecode type="json"><![CDATA[{
  "$id": "https://evidenceangel-schemas.hpkns.uk/testcase.1.schema.json",
  "$schema": "http://json-schema.org/draft-07/schema",
  "type": "object",
  "description": "A test case file `testcases/<UUID>.json` as part of an evidence package.",
  "properties": {
    "metadata": {
      "type": "object",
      "properties": {
        "title": {
          "type": "string",
          "description": "The title of the test case",
          "minLength": 1,
          "maxLength": 30
        },
        "execution_datetime": {
          "type": "string",
          "format": "date-time",
          "description": "The date and time of the execution of this test case starting."
        },
        "passed": {
          "type": ["string", "null"],
          "description": "The state of the test case",
          "enum": [
            "pass",
            "fail",
            null
          ]
        },
        "custom": {
          "type": "object",
          "description": "Custom metadata values",
          "patternProperties": {
            ".+": {
              "type": "string"
            }
          }
        }
      },
      "required": ["title", "execution_datetime"]
    },
    "evidence": {
      "type": "array",
      "items": {
        "type": "object",
        "description": "A piece of evidence as part of this test case.",
        "properties": {
          "kind": {
            "type": "string",
            "description": "The type of data stored. Note that where `Http` is used, a Record Separator character (0x1e) can be used to split the request and response portion.",
            "enum": ["Text", "RichText", "Image", "Http", "File"]
          },
          "value": {
            "type": "string",
            "description": "Either `plain:` followed by plain text, `media:` followed by a media SHA256 hash, or `base64:` followed by a base64 string of data without padding.",
            "pattern": "^(plain:.*)|(media:[0-9a-f]{64})|(base64:[A-z0-9+/]*)$"
          },
          "caption": {
            "type": "string",
            "description": "An optional caption for this piece of evidence."
          },
          "original_filename": {
            "type": "string",
            "description": "The original filename for File evidence"
          }
        },
        "required": ["kind", "value"],
        "if": {
          "properties": {
            "kind": { "const": "File" }
          }
        },
        "else": {
          "not": {
            "required": ["original_filename"]
          }
        }
      }
    }
  },
  "required": ["metadata", "evidence"]
}
]]></sourcecode>
</section>

</back>

</rfc>
