Skip to content

Commit

Permalink
Add schema for the Project XML submission type (#2294)
Browse files Browse the repository at this point in the history
This PR is part of a series meant to improve the submission validation
in CDash. The changes introduce an initial schema for the "Project" XML
file type accepted by the CDash submission process. As in the other PRs,
this schema has been tested against all such existing XML data files in
the CDash repo.
  • Loading branch information
sbelsk authored Jul 3, 2024
1 parent 3455f2b commit 30f39ec
Showing 1 changed file with 38 additions and 0 deletions.
38 changes: 38 additions & 0 deletions app/Validators/Schemas/Project.xsd
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<?xml version="1.0" encoding="Windows-1252"?>
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="Project">
<xs:complexType>
<xs:sequence>
<xs:element name="SubProject" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element name="Path" type="xs:string"/>
<xs:element name="Dependency">
<xs:complexType>
<xs:attribute name="name" type="xs:string" use="required" />
<xs:attribute name="type" type="xs:string" use="optional" />
</xs:complexType>
</xs:element>
<xs:element name="EmailAddresses">
<xs:complexType>
<xs:sequence>
<xs:element name="Email" maxOccurs="unbounded">
<xs:complexType>
<xs:attribute name="address" type="xs:string" use="required" />
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:choice>
</xs:sequence>
<xs:attribute name="name" type="xs:string" use="required" />
<xs:attribute name="group" type="xs:string" use="optional" />
</xs:complexType>
</xs:element>
</xs:sequence>
<xs:attribute name="name" type="xs:string" use="required" />
</xs:complexType>
</xs:element>
</xs:schema>

0 comments on commit 30f39ec

Please sign in to comment.