minor corrections

This commit is contained in:
jomu
2015-02-04 00:18:28 +00:00
parent cae65ce01d
commit 57f0dd007a
4 changed files with 567 additions and 577 deletions

View File

@ -52,7 +52,14 @@
<xs:attribute name="Modified" use="required"/> <xs:attribute name="Modified" use="required"/>
<xs:attribute name="MultipleDataList" use="required" type="xs:string"/> <xs:attribute name="MultipleDataList" use="required" type="xs:string"/>
<xs:attribute name="Name" use="required"/> <xs:attribute name="Name" use="required"/>
<xs:attribute name="RelationshipDeleteBehavior" use="optional" type="soap:RelationshipDeleteBehavior" <xs:attribute name="RelationshipDeleteBehavior" use="optional">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="Restrict" />
<xs:enumeration value="Cascade" />
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="NoThrottleListOperations" use="required" type="xs:string"/> <xs:attribute name="NoThrottleListOperations" use="required" type="xs:string"/>
<xs:attribute name="Ordered" use="required" type="xs:string"/> <xs:attribute name="Ordered" use="required" type="xs:string"/>
<xs:attribute name="PreserveEmptyValues" use="required" type="xs:string"/> <xs:attribute name="PreserveEmptyValues" use="required" type="xs:string"/>
@ -558,13 +565,5 @@
</xs:complexType> </xs:complexType>
</xs:element> </xs:element>
<xs:element name="RelationshipDeleteBehavior">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration>Restrict</xs:enumeration>
<xs:enumeration>Cascade</xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:element>
</xs:schema> </xs:schema>

View File

@ -4,6 +4,7 @@ import de.muehlencord.shared.sharepoint.api.sites.SPSite;
import java.net.MalformedURLException; import java.net.MalformedURLException;
import java.security.KeyManagementException; import java.security.KeyManagementException;
import java.security.NoSuchAlgorithmException; import java.security.NoSuchAlgorithmException;
import org.junit.Ignore;
import org.junit.Test; import org.junit.Test;
/** /**
@ -14,6 +15,7 @@ public class NtlmAuthenticatorTest extends BaseTest {
@Test @Test
@Ignore // Depends on available sharepoint currently
public void testAuthentication() throws MalformedURLException, NoSuchAlgorithmException, KeyManagementException { public void testAuthentication() throws MalformedURLException, NoSuchAlgorithmException, KeyManagementException {
SPSite instance = new SPSite(context); SPSite instance = new SPSite(context);
instance.getRootWeb(); instance.getRootWeb();

View File

@ -35,17 +35,11 @@ public class SPListTest extends BaseTest {
IOException { IOException {
SPLists instance = new SPLists(context); SPLists instance = new SPLists(context);
SPList list = instance.getSpListByTitle("Test"); SPList list = instance.getSpListByTitle("Count");
assertNotNull(list); assertNotNull(list);
String listName = list.getListName(); String listName = list.getListName();
assertEquals("Listname", "{D8C8D97E-1065-4674-A8F2-026D6D478794}", listName); assertEquals("Listname", "{D8C8D97E-1065-4674-A8F2-026D6D478794}", listName);
// get list of all country codes
java.util.List<String> columns = new ArrayList<>();
columns.add("Title");
columns.add("ID");
java.util.List<java.util.List<String>> countryCodes = list.getListItems(columns, "300");
Map<String, String> data = new HashMap<>(); Map<String, String> data = new HashMap<>();
data.put("Title", "Test"); data.put("Title", "Test");
data.put("Choice", "Enter Choice #1"); // is not checked, possible to add wrong value data.put("Choice", "Enter Choice #1"); // is not checked, possible to add wrong value
@ -56,7 +50,7 @@ public class SPListTest extends BaseTest {
} }
@Test @Test
// @Ignore // Depends on available sharepoint currently @Ignore // Depends on available sharepoint currently
public void addListItemBigList() throws NoSuchAlgorithmException, KeyManagementException, JAXBException, SAXException, ParserConfigurationException, public void addListItemBigList() throws NoSuchAlgorithmException, KeyManagementException, JAXBException, SAXException, ParserConfigurationException,
IOException { IOException {

View File

@ -3,12 +3,8 @@ package de.muehlencord.shared.sharepoint.api.lists;
import de.muehlencord.shared.sharepoint.api.BaseTest; import de.muehlencord.shared.sharepoint.api.BaseTest;
import static de.muehlencord.shared.sharepoint.api.BaseTest.readFileContentFromTest; import static de.muehlencord.shared.sharepoint.api.BaseTest.readFileContentFromTest;
import java.io.IOException; import java.io.IOException;
import java.net.MalformedURLException;
import java.security.KeyManagementException;
import java.security.NoSuchAlgorithmException;
import javax.xml.bind.JAXBException; import javax.xml.bind.JAXBException;
import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertEquals;
import org.junit.Before;
import org.junit.Ignore; import org.junit.Ignore;
import org.junit.Test; import org.junit.Test;
import org.xml.sax.SAXException; import org.xml.sax.SAXException;
@ -22,7 +18,6 @@ public class SPListsTest extends BaseTest {
@Test @Test
//@Ignore
public void testFromXML() throws IOException, JAXBException, SAXException { public void testFromXML() throws IOException, JAXBException, SAXException {
String xmlString = readFileContentFromTest("lists/testlists.xml", "UTF-8"); String xmlString = readFileContentFromTest("lists/testlists.xml", "UTF-8");
SPLists lists = new SPLists(context); SPLists lists = new SPLists(context);