@@ -617,6 +617,10 @@ |
||
617 | 617 | $this->changeProjectRepositoriesAccess($project_id, $is_private); |
618 | 618 | } |
619 | 619 | |
620 | + /** |
|
621 | + * @param integer $project_id |
|
622 | + * @param boolean $is_private |
|
623 | + */ |
|
620 | 624 | private function changeProjectRepositoriesAccess($project_id, $is_private) { |
621 | 625 | return GitActions::changeProjectRepositoriesAccess($project_id, $is_private, $this->dao, $this->factory); |
622 | 626 | } |
@@ -94,6 +94,9 @@ discard block |
||
94 | 94 | $this->manager = new GitRepositoryManager($this->factory, mock('Git_SystemEventManager'), $this->dao, $this->backup_directory); |
95 | 95 | } |
96 | 96 | |
97 | + /** |
|
98 | + * @param string $path |
|
99 | + */ |
|
97 | 100 | private function aRepoWithPath($path) { |
98 | 101 | return aGitRepository()->withPath($this->project_name.'/'.$path.'.git')->withProject($this->project)->build(); |
99 | 102 | } |
@@ -229,6 +232,9 @@ discard block |
||
229 | 232 | class GitRepositoryIdMatchExpectation extends SimpleExpectation { |
230 | 233 | private $repository_id; |
231 | 234 | |
235 | + /** |
|
236 | + * @param integer $repository_id |
|
237 | + */ |
|
232 | 238 | public function __construct($repository_id) { |
233 | 239 | parent::__construct(); |
234 | 240 | $this->repository_id = $repository_id; |
@@ -397,6 +403,9 @@ discard block |
||
397 | 403 | $this->manager->forkRepositories($repos, $to_project, $this->user, '', null, $this->forkPermissions); |
398 | 404 | } |
399 | 405 | |
406 | + /** |
|
407 | + * @param string[] $repo_ids |
|
408 | + */ |
|
400 | 409 | protected function getRepoCollectionUnreadableFor($repo_ids, $user) { |
401 | 410 | $return = array(); |
402 | 411 | foreach ($repo_ids as $id) { |
@@ -487,6 +496,9 @@ discard block |
||
487 | 496 | $this->forkRepositories(array($this->repository), '^toto/pouet'); |
488 | 497 | } |
489 | 498 | |
499 | + /** |
|
500 | + * @param integer $id |
|
501 | + */ |
|
490 | 502 | private function GivenARepository($id) { |
491 | 503 | $repo = new MockGitRepository(); |
492 | 504 | $repo->setReturnValue('getId', $id); |
@@ -496,6 +508,9 @@ discard block |
||
496 | 508 | return $repo; |
497 | 509 | } |
498 | 510 | |
511 | + /** |
|
512 | + * @param string $namespace |
|
513 | + */ |
|
499 | 514 | private function forkRepositories($repositories, $namespace=null) { |
500 | 515 | $this->manager->forkRepositories($repositories, $this->project, $this->user, $namespace, null, $this->forkPermissions); |
501 | 516 | } |
@@ -140,6 +140,10 @@ |
||
140 | 140 | $this->assertEqual('u/johan/tulip', $repo->getFullName()); |
141 | 141 | } |
142 | 142 | |
143 | + /** |
|
144 | + * @param string $name |
|
145 | + * @param null|string $namespace |
|
146 | + */ |
|
143 | 147 | protected function _GivenARepositoryWithNameAndNamespace($name, $namespace) { |
144 | 148 | $repo = new GitRepository(); |
145 | 149 | $repo->setName($name); |
@@ -229,6 +229,9 @@ discard block |
||
229 | 229 | $this->assertItNeedsAValidRepoId(); |
230 | 230 | } |
231 | 231 | |
232 | + /** |
|
233 | + * @param Codendi_Request $request |
|
234 | + */ |
|
232 | 235 | protected function getGit($request, $factory) { |
233 | 236 | $git = parent::getGit($request, $factory); |
234 | 237 | $git->setAction('disconnect_gerrit'); |
@@ -332,6 +335,9 @@ discard block |
||
332 | 335 | $git->request(); |
333 | 336 | } |
334 | 337 | |
338 | + /** |
|
339 | + * @param Codendi_Request $request |
|
340 | + */ |
|
335 | 341 | protected function getGit($request, $factory, $template_factory = null) { |
336 | 342 | $git = parent::getGit($request, $factory, $template_factory); |
337 | 343 | $git->setAction('migrate_to_gerrit'); |
@@ -26,6 +26,9 @@ |
||
26 | 26 | |
27 | 27 | abstract class GitViewsRepositoriesTraversalStrategyTest extends TuleapTestCase { |
28 | 28 | |
29 | + /** |
|
30 | + * @param string $classname |
|
31 | + */ |
|
29 | 32 | public function __construct($classname) { |
30 | 33 | parent::__construct(); |
31 | 34 | $this->classname = $classname; |
@@ -86,6 +86,9 @@ discard block |
||
86 | 86 | |
87 | 87 | } |
88 | 88 | |
89 | + /** |
|
90 | + * @param string $unixName |
|
91 | + */ |
|
89 | 92 | private function GivenAProject($id, $name, $unixName = null, $useGit = true) { |
90 | 93 | $project = new MockProject(); |
91 | 94 | $project->setReturnValue('getId', $id); |
@@ -95,6 +98,10 @@ discard block |
||
95 | 98 | return $project; |
96 | 99 | } |
97 | 100 | |
101 | + /** |
|
102 | + * @param string $id |
|
103 | + * @param string $name |
|
104 | + */ |
|
98 | 105 | private function GivenAProjectWithoutGitService($id, $name) { |
99 | 106 | return $this->GivenAProject($id, $name, null, false); |
100 | 107 | } |
@@ -245,6 +245,9 @@ |
||
245 | 245 | $this->assertEqual(GitRepository::DEFAULT_DESCRIPTION, $this->git_dao->last_saved_repository->getDescription()); |
246 | 246 | } |
247 | 247 | |
248 | + /** |
|
249 | + * @param SimpleXMLElement $xml |
|
250 | + */ |
|
248 | 251 | private function import($xml) { |
249 | 252 | return $this->importer->import($this->project, mock('PFUSer'), $xml, parent::getTmpDir()); |
250 | 253 | } |
@@ -81,7 +81,6 @@ |
||
81 | 81 | /** |
82 | 82 | * Display the report list |
83 | 83 | * |
84 | - * @param : $reports the list the reports within an artifact to display |
|
85 | 84 | * |
86 | 85 | * @return void |
87 | 86 | */ |
@@ -34,6 +34,9 @@ discard block |
||
34 | 34 | $this->table_name = 'plugin_graphontrackers_chart'; |
35 | 35 | } |
36 | 36 | |
37 | + /** |
|
38 | + * @param string $report_id |
|
39 | + */ |
|
37 | 40 | public function searchByReportId($report_id) { |
38 | 41 | $sql = "SELECT * FROM plugin_graphontrackers_chart WHERE report_graphic_id = "; |
39 | 42 | $sql .= $this->da->escapeInt($report_id); |
@@ -53,6 +56,11 @@ discard block |
||
53 | 56 | return $this->update($sql); |
54 | 57 | } |
55 | 58 | |
59 | + /** |
|
60 | + * @param string $report_id |
|
61 | + * @param string $title |
|
62 | + * @param string $description |
|
63 | + */ |
|
56 | 64 | public function create($report_id, $chart_type, $title, $description, $width, $height) { |
57 | 65 | $rank = $this->prepareRanking(0, $report_id, 'beginning', 'id', 'report_graphic_id'); |
58 | 66 | $sql = sprintf("INSERT INTO plugin_graphontrackers_chart(report_graphic_id, rank, chart_type, title, description, width, height) VALUES (%d, %d, %s, %s, %s, %d, %d)", |