public function testGitHubAuthentication() { $remote = new GitHubRemote(); $this->assertEquals([], $remote->getAuthenticationPart()); $remote->setOptions(['personal_token' => 'testpersonaltoken', 'username' => 'testusername']); $this->assertEquals(['auth' => ['testusername', 'testpersonaltoken']], $remote->getAuthenticationPart()); $repository = new GitHubRepository('text/test', 'just a test', $anon = 'https://github.com/test/test.git'); $repository->setRemote($remote); $this->assertEquals($anon, $repository->getAnonymousUri()); $this->assertEquals('https://*****:*****@github.com/test/test.git', $repository->getUri()); }