This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package com.facebook; | |
| import java.util.ArrayList; | |
| import java.util.Collection; | |
| public class AccessTokenCreator { | |
| public static AccessToken createToken(Collection<String> grantedPermissions) { | |
| return new AccessToken("token", "appId", "userId", grantedPermissions, | |
| new ArrayList<String>(), AccessTokenSource.WEB_VIEW, null, null); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import org.apache.http.HeaderElement; | |
| import org.apache.http.HeaderElementIterator; | |
| import org.apache.http.HttpResponse; | |
| import org.apache.http.client.config.RequestConfig; | |
| import org.apache.http.config.Registry; | |
| import org.apache.http.config.RegistryBuilder; | |
| import org.apache.http.conn.ConnectionKeepAliveStrategy; | |
| import org.apache.http.conn.socket.ConnectionSocketFactory; | |
| import org.apache.http.conn.socket.PlainConnectionSocketFactory; | |
| import org.apache.http.conn.ssl.SSLConnectionSocketFactory; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| angular.module('stateMock',[]); | |
| angular.module('stateMock').service("$state", function($q){ | |
| this.expectedTransitions = []; | |
| this.transitionTo = function(stateName){ | |
| if(this.expectedTransitions.length > 0){ | |
| var expectedState = this.expectedTransitions.shift(); | |
| if(expectedState !== stateName){ | |
| throw Error("Expected transition to state: " + expectedState + " but transitioned to " + stateName ); | |
| } | |
| }else{ |