Commit Graph

25 Commits

Author SHA1 Message Date
Henrik Andersson fafbf33b78 Implement Draft Pull Requests (#2009)
* Add draft PR preview header

* Add Draft property to models

* Update pull requests client and tests to use draft PR accept header

* Update observable pull requests client and tests to use draft PR accept header

* Add integration tests to create and retrieve draft pull requests
2019-09-22 13:38:56 -03:00
Ryan Gribble 600c8657e4 Remove method/members previously deprecated (#1780)
* removes obsolete OranizationsClient.GetAll (replaced with GetAllForUser)

* removes obsolete PullRequestsClient.Comment (replaced with ReviewComment)

* removes obsolete TeamsClient.GetMembership (replaced with GetMembershipDetails)
removes obsolete TeamsClient.AddMembership (replaced with AddOrEditMembership)
removes obsolete TeamsClient.AddMembership (replaced with AddOrEditMembership)
removes obsolete TeamMembership response class (replaced with TeamMembershipDetails)

* removes obsolete RepositoryBranchesClient.GetRequiredStatusChecksContexts (replaced with GetAllRequiredStatusChecksContexts)
removes obsolete RepositoryBranchesClient.GetProtectedBranchTeamRestrictions (replaced with GetAllProtectedBranchTeamRestrictions)
removes obsolete RepositoryBranchesClient.GetProtectedBranchUserRestrictions (replaced with GetAllProtectedBranchUserRestrictions)

* removes obsolete RepositoryTrafficClient.GetReferrers (replaced with GetAllReferrers)
removes obsolete RepositoryTrafficClient.GetPaths (replaced with GetAllPaths)

* removes obsolete constructors from BranchProtectionUpdateSettings and UpdateTeam request models

* removes obsolete Assignee property from NewIssue and IssueUpdate request models (replaced with Assignees)
2018-04-22 09:58:06 +10:00
Itai Bar-Haim 4e804f61a6 Prefer using nameof(x) over literal "x" (#1781)
* updated XML docs and added some missing bits.

* prefer nameof(x) over literal "x"
2018-03-07 20:43:10 +10:00
Travis Harris ff9521ce3d Implement Review API for Pull Requests (#1648)
* First Iteration Need to finish tests and docs

* Mostly Complete

* Fixing tests and adding review comments

* Added tests for reactive client

* Moved Reviews inside fo the Pull request client for better organization and began initial intigration testing

* Fixing bad recursive function breaking tests

* test fixes

* Add paging support to review comments call

* Fixing recursive function

* Addressing comments from PR

* fixing CI break

* Typo build break

* Fixing Convention Tests

* Adding correct nameof() usage in Ensure

* Small consitancy changes

* Trigger build

* Address PR Comments

* Fixup test naming

* Fix sub client ordering and incorrect URL

* Tidy up comments and remove StringEnum wrapper from Request models as it is only for Response models

* Rename GetReview to Get

* tweak debugger display

* Rework integration tests - implement the easy Get/GetAll ones first...

* Implement integration tests for Create method.
Move helpers to create PR/review into SetupHelper class
Fixed up review status enum to contain correct values
Tests for Approve/RequestChanges currently failing as a user cant approve/request changes on their own PR

* Implement secondary account settings for integration tests and a new [DualAccountTest] attribute for discovery when configured
Change integration test to create PR from the 2nd account, so the main test account is able to perform review actions on the PR

* Add integration tests for Delete, Dismiss and Submit methods
Fixed up API client implementation for delete (was looking for incorrect 201 http status)
Removed unnecessary await/async calls from client implementations that dont need to do anything with the result

* Attempting to add comments as part of a review revealed that we cant use the existing PullRequestReviewCommentCreate class as the API throws a validation error due to the CommitId field
These newer review APIs need a DraftPullRequestReviewComment (that doesnt have a commitId) instead

* add second test account user/password to configure-integration-tests script
2017-08-16 20:50:25 +10:00
Grzegorz Dziadkiewicz 97ae3cb3de Add Pull Request Review Request API. (#1588)
* Add Pull Request Review Request API.

* Add Reactive Pull Request Review Request API.

* Add PullRequestReviewRequestClient tests.

* Add ObservablePullRequestReviewRequestClient tests.

* Fix sub-client property naming.

* Remove redundant model and update PullRequest model.

* Add repositoryId based methods and missing Observable documentation.

* Add missing parameter to PullRequest ctor.

* Add integration tests for PullRequestReviewRequest.

* Upgrade PullRequestReviewRequest integration tests.

* Add integration tests for repositoryId methods and fix url bug.

* Add missing unit tests and fix PR issues.

* Add pagination support for PullRequestReviewRequst.GetAll and tests for it.

* Revert changes on `PullRequestReviewCommentsClientTests.cs`

* Small upgrades - remove unused using and compress property to expression body.

* Revert use of expression body in property.

* Add pagination tests for PullRequestReviewRequest.GetAll.

* Change pagination tests to use 2 users.

* Correct class/file name

* Reword the integration test names for consistency
Move the plumbing to create reviews into CreateTheWorld to clean up the actual tests

* Fix DebuggerDisplay of requested reviewers

* fix reviewRequestToCreate parameter to be consistent
2017-05-14 22:07:57 +10:00
Brandon Everett 155073b138 [WIP] Rename Comment to ReviewComment (#1520)
* obsolete comment and add ReviewComment

* obsolete PullRequest.Comment and change to ReviewComment

* update ObservablePullRequestClient and interface to use ReviewComment

* fixed formatting issues
have Comment return new ReviewComment
2016-12-31 19:21:40 +10:00
Andreia Gaita 9e958bf998 Make Repository Id a long, it's going to grow... 2016-09-15 02:15:11 +02:00
aedampir@gmail.com 44b0f4039d ID -> Id 2016-07-17 16:29:32 +07:00
aedampir@gmail.com b9e82086b5 burned <returns> tags 2016-07-06 02:27:38 +07:00
Alexander Efremov 3fefc4879e cleared <returns> tags 2016-06-17 05:44:24 +07:00
aedampir@gmail.com 691eded548 modified XML docs
added new overloads
2016-06-16 19:15:20 +07:00
aedampir@gmail.com 6ece0ef037 added new overloads 2016-05-25 13:27:44 +07:00
Brendan Forster 80719c0033 aaaand format the code 2015-11-04 13:38:51 -08:00
Henrik Andersson 2427ab6922 Update observable clients 2015-03-24 00:12:41 +10:00
Henrik Andersson f730846713 Add method for getting all files for a PR 2015-03-19 09:57:19 +10:00
Gabriel Weyer f23ddf81f9 Finalized integration testing for review comments 2014-05-04 10:46:35 +10:00
Peter MacNaughton 04d6e9b386 Generate documentation comments for the
`Reactive` project
2014-02-26 22:22:59 -07:00
Brendan Forster 1231b794b1 bugfix for PR commits having different shape to regular commits 2014-02-18 20:20:37 +11:00
Brendan Forster 93b8b27a0b updated docs 2014-02-18 19:48:51 +11:00
Brendan Forster 3f306fb9b0 address some documentation feedback 2014-02-03 19:16:27 +11:00
Josh Sullivan 14236cd926 Merged now returns bool based on the request http response 2014-02-03 18:58:45 +11:00
Josh Sullivan 0db0307aa9 Pull request commit list now implemented / tested
Renamed and enhanced existing Merged tests.
2014-02-03 18:58:41 +11:00
Josh Sullivan 9d3f7581e7 Implemented Merged? functionality / tests
Bugfix for building the merge api url, as well.
2014-02-03 18:41:28 +11:00
Josh Sullivan fddae25b6f Implemented pull request merge functionality 2014-02-03 18:31:08 +11:00
Josh Sullivan dd220d7bf9 Stubbed out the reactive Pull Request functionality 2014-02-03 18:31:04 +11:00