import Testing @testable import PureXML @Suite("simpleContent restriction inline simpleType") struct SimpleContentInlineTypeTests { @Test("an inline list simpleType is not a restriction of an atomic decimal simpleContent base") func test_listInlineTypeOverDecimalBaseRejected() { let schema = """ """ #expect((try? PureXML.Schema.Document(schema)) == nil) } @Test("a valid inline atomic restriction becomes the effective simpleContent type") func test_validInlineTypeRestrictsInstanceValues() throws { let schema = try PureXML.Schema.Document(""" """) #expect(try schema.validate(#"5"#).isEmpty) #expect(try !schema.validate(#"1.5"#).isEmpty) #expect(try !schema.validate(#"11"#).isEmpty) } }