Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implementations of the missing RepositoriesClient methods #319

Merged
merged 5 commits into from
Feb 18, 2014

Conversation

pmacn
Copy link

@pmacn pmacn commented Jan 22, 2014

There are some concerns regarding naming here to be aware of. Specifically the response model RepositoryTag. A class named GitTag already exists but the structures are quite different. It looks as if this might be more in line with a lightweight tag so LightweightTag might do as a name instead.

Secondly the builder implementation in the integration tests is silly at this point, but it felt even sillier repeating the longer section over and over. And this way the option to change the defaults is more centralized and it's easy to add methods to the builder for more customization if it's ever needed. I can take it or leave it but if it stays I have another commit that replaces the hardcoded instantiations throughout the integration tests.

Hopefully there aren't many other issues :)

@haacked
Copy link
Contributor

haacked commented Jan 22, 2014

I think RepositoryTag is fine since this is the only place that I could find where this structure is used. If there were more than one place, then a more generic name would be appropriate.

@pmacn
Copy link
Author

pmacn commented Jan 22, 2014

/// Optional. Gets or sets whether to the enable the wiki for the repository.

I guess that's what I get for copying existing comments and then modifying them. Forgot to remove the first "the". And apparently I did it for all of the comments that have the same format. I'll sort that out after work.

@pmacn
Copy link
Author

pmacn commented Jan 22, 2014

Or maybe on the lunch break, because waiting until after work is just too long.

@pmacn pmacn mentioned this pull request Jan 22, 2014
using System.Threading.Tasks;
using Octokit;
using Octokit.Tests.Integration;
using Xunit;
using System;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tidy up these using statements

@pmacn
Copy link
Author

pmacn commented Feb 10, 2014

Regarding AssertEx.DoesNotAllowNullArguments and DoesNotAllowEmptyStringArguments.
I put these in here simply as a way to put the idea forward. I probably should have put them in their own pull request. I got carried away, my bad.
If it's not something we're interested in I'll take them out and replace with the old tests for ensures.

@shiftkey
Copy link
Member

I put these in here simply as a way to put the idea forward. I probably should have put them in their own pull request. I got carried away, my bad.

Let's address those separately - personally I don't mind seeing the null parameters there, but I'm open to alternatives...

Peter MacNaughton added 3 commits February 10, 2014 00:09
Added unit tests for newly added methods
Added models RepositoryTag, RepositoryLanguage and RepositoryUpdate
sitoriesClient
Added unit tests for new methods.
@pmacn
Copy link
Author

pmacn commented Feb 10, 2014

Removed the assertion methods and cleaned up the commits.


var contributors = await github.Repository.GetAllContributors("octokit", "octokit.net");

Assert.True(contributors.Any(c => c.Login == "pmacn"));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high-five-fist-bump-gif

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indulging in a little bit of self gratification

@shiftkey
Copy link
Member

Ok, I think this one is good to go. Merge master in and 💥

Conflicts:
	Octokit.Reactive/Clients/IObservableRepositoriesClient.cs
	Octokit.Reactive/Clients/ObservableRepositoriesClient.cs
	Octokit/Helpers/ApiUrls.cs
	Octokit/Octokit-Mono.csproj
	Octokit/Octokit-MonoAndroid.csproj
	Octokit/Octokit-Monotouch.csproj
	Octokit/Octokit-netcore45.csproj
@pmacn
Copy link
Author

pmacn commented Feb 18, 2014

@shiftkey merged~

@pmacn
Copy link
Author

pmacn commented Feb 18, 2014

I did just realize that I didn't add a DebuggerDisplayAttribute on the RepositoryUpdate class however

@pmacn
Copy link
Author

pmacn commented Feb 18, 2014

@shiftkey Should be all done now

haacked added a commit that referenced this pull request Feb 18, 2014
Implementations of the missing RepositoriesClient methods
@haacked haacked merged commit abf0a47 into octokit:master Feb 18, 2014
@pmacn pmacn deleted the repositoriesclient branch February 18, 2014 04:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants