public void SignUrl_adds_oauth_signature()
		{
			var url = "http://www.example.com?parameter=hello&again=there";

			var signedUrl = new UrlSigner().SignUrl(url, null, null, GetOAuthCredentials());
			Assert.That(signedUrl.Query.Contains("oauth_signature"));
		}
		public void SetUp() {
			IOAuthCredentials oAuthCredentials = EssentialDependencyCheck<IOAuthCredentials>.Instance;
			IApiUri apiUri = EssentialDependencyCheck<IApiUri>.Instance;
			var httpGetResolver = new HttpGetResolver();
			var urlSigner = new UrlSigner();

			_endpointResolver = new EndpointResolver(httpGetResolver, urlSigner, oAuthCredentials, apiUri);
		}
		public void SetUp() 
		{
			IOAuthCredentials oAuthCredentials = EssentialDependencyCheck<IOAuthCredentials>.Instance;
			IApiUri apiUri = EssentialDependencyCheck<IApiUri>.Instance;
			var httpGetResolver = new HttpClient();
			var urlSigner = new UrlSigner();

			_requestCoordinator = new RequestCoordinator(httpGetResolver, urlSigner, oAuthCredentials, apiUri);
		}
		public void SignUrlAsString_escapes_those_stupid_plus_signs_and_other_evils_in_signature()
		{
			var url = "http://www.example.com?parameter=hello&again=there";

			for (int i = 0; i < 50; i++)
			{
				var signedUrl = new UrlSigner().SignUrlAsString(url, null, null, GetOAuthCredentials());
				var index = signedUrl.IndexOf("oauth_signature");
				var signature = signedUrl.Substring(index + "oauth_signature".Length);

				Assert.That(!signature.Contains("+"), "signature contains a '+' character and isn't being encoded properly");
			}
		}
		public void SetUp()
		{
			_signatureGenerator = A.Fake<ISignatureGenerator>();
			_urlSigner = new UrlSigner(_signatureGenerator);
		}