-
Notifications
You must be signed in to change notification settings - Fork 801
Required changes for 3.0.0 preview3 #112
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
Merged
Merged
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
9e5feb6
Required changes for 3.0.0 preview3
9fd48f6
Update test/Grpc.AspNetCore.Server.Tests/GrpcEndpointRouteBuilderExte…
JamesNK 4335078
Update test/Grpc.AspNetCore.Server.Tests/GrpcEndpointRouteBuilderExte…
JamesNK 561b4dd
Feedback
440e8af
cleanup
aed8df0
Add script to install SDK
6bdce8b
Source the script to add dotnet to path
b930cae
Add dotnet to path
82a5c0e
Add ps script to install SDK
59a5504
Update
2838a2a
Add a HttpResponseStartFeature
d02f434
Nope that didn't work
e7e4a99
Feedback
d9f440f
Comments
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#!/usr/bin/env powershell | ||
|
||
<# | ||
.PARAMETER Upgrade | ||
Upgrade the version of gRPC packages to be downloaded to the latest on https://packages.grpc.io/ | ||
.NOTES | ||
This function will create a file grpc-lock.txt. This lock file can be committed to source, but does not have to be. | ||
When the lock file is not present, the script will create one using latest available version from https://packages.grpc.io/. | ||
#> | ||
|
||
param ( | ||
[switch]$Upgrade = $false | ||
) | ||
|
||
Set-StrictMode -Version 2 | ||
$ErrorActionPreference = 'Stop' | ||
|
||
# Variables | ||
|
||
$WorkingDir = $PSScriptRoot | ||
$TempDir = Join-Path $WorkingDir 'obj' | ||
$InstallScriptUrl = 'https://dot.net/v1/dotnet-install.ps1' | ||
$InstallScriptPath = Join-Path $TempDir 'dotnet-install.ps1' | ||
$GlobalJsonPath = Join-Path $WorkingDir '..' | Join-Path -ChildPath 'global.json' | ||
|
||
# Functions | ||
|
||
function Ensure-Dir([string]$path) { | ||
if (!(Test-Path $path -PathType Container)) { | ||
New-Item -ItemType Directory -Force -Path $path | Out-Null | ||
} | ||
} | ||
|
||
# Main | ||
|
||
# Resolve SDK version | ||
$GlobalJson = Get-Content -Raw $GlobalJsonPath | ConvertFrom-Json | ||
$SDKVersion = $GlobalJson.sdk.version | ||
|
||
# Download install script | ||
Ensure-Dir $TempDir | ||
Write-Host "Downloading install script: $InstallScriptUrl => $InstallScriptPath" | ||
Invoke-WebRequest -Uri $InstallScriptUrl -OutFile $InstallScriptPath | ||
&$InstallScriptPath -Version $SDKVersion |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
#!/usr/bin/env bash | ||
|
||
set -euo pipefail | ||
|
||
# variables | ||
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )" | ||
OBJDIR="$DIR/obj" | ||
global_json_path="$DIR/../global.json" | ||
install_script_url="https://dot.net/v1/dotnet-install.sh" | ||
install_script_path="$OBJDIR/dotnet-install.sh" | ||
|
||
# functions | ||
ensure_dir() { | ||
[ -d $1 ] || mkdir $1 | ||
} | ||
|
||
# main | ||
|
||
# resolve SDK version | ||
sdk_version=$(jq -r .sdk.version $global_json_path) | ||
|
||
# download dotnet-install.sh | ||
ensure_dir $OBJDIR | ||
|
||
echo "Downloading install script: $install_script_url => $install_script_path" | ||
curl -sSL -o $install_script_path $install_script_url | ||
chmod +x $install_script_path | ||
|
||
$install_script_path -v $sdk_version |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"sdk": { | ||
"version": "3.0.100-preview-010184" | ||
"version": "3.0.100-preview3-010313" | ||
JunTaoLuo marked this conversation as resolved.
Show resolved
Hide resolved
|
||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
testassets/FunctionalTestsWebsite/Infrastructure/TestHttpResponseStartFeature.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
#region Copyright notice and license | ||
|
||
// Copyright 2019 The gRPC Authors | ||
// | ||
// Licensed under the Apache License, Version 2.0 (the "License"); | ||
// you may not use this file except in compliance with the License. | ||
// You may obtain a copy of the License at | ||
// | ||
// http://www.apache.org/licenses/LICENSE-2.0 | ||
// | ||
// Unless required by applicable law or agreed to in writing, software | ||
// distributed under the License is distributed on an "AS IS" BASIS, | ||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
// See the License for the specific language governing permissions and | ||
// limitations under the License. | ||
|
||
#endregion | ||
|
||
using System.Threading; | ||
using System.Threading.Tasks; | ||
using Microsoft.AspNetCore.Http.Features; | ||
|
||
namespace FunctionalTestsWebsite.Infrastructure | ||
{ | ||
internal class TestHttpResponseStartFeature : IHttpResponseStartFeature | ||
{ | ||
public Task StartAsync(CancellationToken token = default(CancellationToken)) | ||
{ | ||
return Task.CompletedTask; | ||
} | ||
} | ||
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.