Browse Source

Remove duplicate copy of flight.xsd

See 85eb589c2e
See gh-25787
pull/26893/head
Sam Brannen 4 years ago
parent
commit
091e7bb891
  1. 5
      spring-oxm/src/test/java/org/springframework/oxm/jaxb/Jaxb2UnmarshallerTests.java
  2. 20
      spring-oxm/src/test/resources/org/springframework/oxm/flight.xsd

5
spring-oxm/src/test/java/org/springframework/oxm/jaxb/Jaxb2UnmarshallerTests.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-2019 the original author or authors.
* Copyright 2002-2021 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -31,6 +31,7 @@ import javax.xml.transform.stream.StreamSource; @@ -31,6 +31,7 @@ import javax.xml.transform.stream.StreamSource;
import org.junit.jupiter.api.Test;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.FileSystemResource;
import org.springframework.core.io.Resource;
import org.springframework.oxm.AbstractUnmarshallerTests;
import org.springframework.oxm.jaxb.test.FlightType;
@ -56,7 +57,7 @@ public class Jaxb2UnmarshallerTests extends AbstractUnmarshallerTests<Jaxb2Marsh @@ -56,7 +57,7 @@ public class Jaxb2UnmarshallerTests extends AbstractUnmarshallerTests<Jaxb2Marsh
protected Jaxb2Marshaller createUnmarshaller() throws Exception {
Jaxb2Marshaller unmarshaller = new Jaxb2Marshaller();
unmarshaller.setContextPath("org.springframework.oxm.jaxb.test");
unmarshaller.setSchema(new ClassPathResource("org/springframework/oxm/flight.xsd"));
unmarshaller.setSchema(new FileSystemResource("src/test/schema/flight.xsd"));
unmarshaller.afterPropertiesSet();
return unmarshaller;
}

20
spring-oxm/src/test/resources/org/springframework/oxm/flight.xsd

@ -1,20 +0,0 @@ @@ -1,20 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<schema xmlns="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified"
targetNamespace="http://samples.springframework.org/flight"
xmlns:tns="http://samples.springframework.org/flight">
<element name="flights">
<complexType>
<sequence>
<element name="flight" type="tns:flightType"
maxOccurs="unbounded">
</element>
</sequence>
</complexType>
</element>
<element name="flight" type="tns:flightType"/>
<complexType name="flightType">
<sequence>
<element name="number" type="long"/>
</sequence>
</complexType>
</schema>
Loading…
Cancel
Save