initial commit
This commit is contained in:
@ -0,0 +1,25 @@
|
||||
package de.muehlencord.shared.sharepoint.api;
|
||||
|
||||
import de.muehlencord.shared.sharepoint.api.sites.SPSite;
|
||||
import java.net.MalformedURLException;
|
||||
import java.net.URL;
|
||||
import org.junit.Test;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author jomu
|
||||
*/
|
||||
public class NtlmAuthenticatorTest {
|
||||
|
||||
|
||||
|
||||
@Test
|
||||
public void testAuthentication() throws MalformedURLException {
|
||||
// Create NTLM v2 credentials (authenticator) & setup context
|
||||
NtlmAuthenticator credentials = new NtlmAuthenticator("DOMAIN", "username", "password");
|
||||
SPContext context = new SPContext(new URL ("http://localhost:8088/"), credentials, SPVersion.SP2010);
|
||||
// Connect to Sharepoint
|
||||
SPSite instance = new SPSite(context);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user