Пример #1
0
        public void UriGenerationForDuplicateController()
        {
            var router =
                new GitHubApiRouter(new Uri("http://localhost/"));

            var url = router.GetUrlForController(typeof(GistController),"star");

            Assert.Equal("http://localhost/gists/{gistid}/star", url.OriginalString);
        }
Пример #2
0
        public void UriGenerationForDuplicateController()
        {
            var router =
                new GitHubApiRouter(new Uri("http://localhost/"));

            var url = router.GetUrlForController(typeof(GistController), "star");

            Assert.Equal("http://localhost/gists/{gistid}/star", url.OriginalString);
        }
Пример #3
0
        public void UriGeneration()
        {
            var router =
                new GitHubApiRouter(new Uri("http://localhost/"));

            var url = router.GetUrlForController(typeof(RepoLabelsController));

            Assert.Equal("http://localhost/repos/{userid}/{repoid}/labels", url.OriginalString);
        }
Пример #4
0
        public void UriGeneration()
        {
            var router =
                new GitHubApiRouter(new Uri("http://localhost/"));

            var url = router.GetUrlForController(typeof(RepoLabelsController));

            Assert.Equal("http://localhost/repos/{userid}/{repoid}/labels", url.OriginalString);
        }