Merge pull request #702 from octokit/release-candidate

0.7.0 - All Torn Down
This commit is contained in:
Brendan Forster
2015-02-24 09:48:25 +10:30
5 changed files with 22 additions and 10 deletions
+1 -1
View File
@@ -439,7 +439,7 @@ namespace Octokit.Tests.Http
httpClient.Received().Send(Arg.Is<IRequest>(req =>
req.BaseAddress == _exampleUri &&
req.Body == body &&
req.Headers["Accept"] == "application/vnd.github.v3+json; charset=utf-8" &&
req.Headers["Accept"] == "application/vnd.github.moondragon+json; charset=utf-8,application/vnd.github.v3+json; charset=utf-8" &&
req.ContentType == "application/arbitrary" &&
req.Method == HttpMethod.Post &&
req.Endpoint == new Uri("https://other.host.com/path?query=val")), Args.CancellationToken);
+1 -1
View File
@@ -30,7 +30,7 @@ namespace Octokit.Tests.Http
jsonPipeline.SerializeRequest(request);
Assert.Contains("Accept", request.Headers.Keys);
Assert.Equal("application/vnd.github.v3+json; charset=utf-8", request.Headers["Accept"]);
Assert.Equal("application/vnd.github.moondragon+json; charset=utf-8,application/vnd.github.v3+json; charset=utf-8", request.Headers["Accept"]);
}
[Fact]
+5 -1
View File
@@ -11,6 +11,9 @@ namespace Octokit.Internal
/// </summary>
public class JsonHttpPipeline
{
private const string moondragonPreviewApiVersion = "application/vnd.github.moondragon+json; charset=utf-8";
private const string v3ApiVersion = "application/vnd.github.v3+json; charset=utf-8";
readonly IJsonSerializer _serializer;
public JsonHttpPipeline() : this(new SimpleJsonSerializer())
@@ -30,7 +33,8 @@ namespace Octokit.Internal
if (!request.Headers.ContainsKey("Accept"))
{
request.Headers["Accept"] = "application/vnd.github.v3+json; charset=utf-8";
request.Headers["Accept"] = String.Join(",", moondragonPreviewApiVersion, v3ApiVersion);
}
if (request.Method == HttpMethod.Get || request.Body == null) return;
+12 -4
View File
@@ -1,9 +1,17 @@
### New in 0.6.3 (Released ???/??/??)
* ...
### New in 0.7.0 (Released 2015/02/24)
* New: Response models now use read-only properties - #658, #662 via @haacked, #663 via @khellang, #679 via @Zoltu
* New: Added `Truncated` property to `TreeResponse` - #674 via @Zoltu
* New: Added `GetRecursive` method to `ITreesClient` - #673 via @Zoltu
* New: Added `Merging` client to `Repository` API: - #603 via @tabro
* New: API internals are now read-only - #662 via @haacked
* Fixed: Commit Status API now supports combined status- #618 via @khellang
* Fixed: Changed `IGistCommentsClient` identifiers to `string` instead of `int` - #681 via @thedillonb
* Fixed: Improved error message when repository creation fails - #667 via @gabrielweyer
* Fixed: Team membership API was incorrect - #695 via @aneville
**Breaking Changes**
- Response models are all read only.
- Response models are all read only. It is recommended that you subclass the
model class if you need to contructor responses (e.g. for testing)
- `IResponse` is now a `readonly` interface.
- `ApiResponse<T>` accepts the strongly typed body as an argument.
- `IResponse<T> changed to `IApiResponse<T>`.
+3 -3
View File
@@ -3,11 +3,11 @@ using System.Reflection;
using System.Runtime.InteropServices;
[assembly: AssemblyProductAttribute("Octokit")]
[assembly: AssemblyVersionAttribute("0.6.3")]
[assembly: AssemblyFileVersionAttribute("0.6.3")]
[assembly: AssemblyVersionAttribute("0.7.0")]
[assembly: AssemblyFileVersionAttribute("0.7.0")]
[assembly: ComVisibleAttribute(false)]
namespace System {
internal static class AssemblyVersionInformation {
internal const string Version = "0.6.3";
internal const string Version = "0.7.0";
}
}