public void EnsuresNonNullArguments()
            {
                var deployKeysClient = new ObservableRepositoryDeployKeysClient(Substitute.For<IGitHubClient>());

                Assert.Throws<ArgumentNullException>(() => deployKeysClient.Get(null, "repo", 42));
                Assert.Throws<ArgumentException>(() => deployKeysClient.Get("", "repo", 42));
                Assert.Throws<ArgumentNullException>(() => deployKeysClient.Get("user", null, 42));
                Assert.Throws<ArgumentException>(() => deployKeysClient.Get("user", "", 42));
            }
            public void RequestsCorrectUrlWithRepositoryId()
            {
                var gitHubClient = Substitute.For<IGitHubClient>();
                var deployKeysClient = new ObservableRepositoryDeployKeysClient(gitHubClient);

                deployKeysClient.Get(1, 42);

                gitHubClient.Repository.DeployKeys.Received(1).Get(1, 42);
            }
            public void CallsIntoClient()
            {
                var githubClient = Substitute.For<IGitHubClient>();
                var deployKeysClient = new ObservableRepositoryDeployKeysClient(githubClient);

                deployKeysClient.Get("user", "repo", 42);

                githubClient.Repository.DeployKeys.Received(1).Get("user", "repo", 42);
            }