Skip to content

[TEST] Run to see failing tests #2665

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

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 1 addition & 16 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
name: "Build"
env:
DotNetVersion: "9.0.101"
DotNetVersion2: "8.0.303"
DotNetVersion3: "7.0.410"
DotNetVersion4: "6.0.203" # This is the last version Mono supports. It is used for our Mono CI tests.
NuGetVersion: "6.5.0"
MonoVersion: "6.12.0"
DotNetVersion2: "8.0.404"
Artifacts: ${{ github.workspace }}/artifacts/
Coverage: ${{ github.workspace }}/coverage/
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: "true"
Expand Down Expand Up @@ -35,28 +31,17 @@ jobs:
clean: "false"
fetch-depth: "0"

- name: Setup NuGet.exe
uses: nuget/setup-nuget@v1
with:
nuget-version: ${{ env.NuGetVersion }}

- name: 🔨 Use .NET Core SDKs
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
${{ env.DotNetVersion4 }}
${{ env.DotNetVersion3 }}
${{ env.DotNetVersion2 }}
${{ env.DotNetVersion }}

- name: 🎁 dotnet tool restore
run: |
dotnet tool restore

- name: 🎁 nuget install
run: |
nuget install tools/packages.config -ExcludeVersion -OutputDirectory tools

- name: 🍰 Run Cake
run: |
dotnet cake --configuration=Release --verbosity=Verbose --target=CI --publish-all --archive
Expand Down
81 changes: 0 additions & 81 deletions .github/workflows/tests-net6.yml

This file was deleted.

19 changes: 2 additions & 17 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
name: "Tests"
env:
DotNetVersion: "9.0.101"
DotNetVersion2: "8.0.303"
DotNetVersion3: "7.0.410"
DotNetVersion4: "6.0.203" # This is the last version Mono supports. It is used for our Mono CI tests.
NuGetVersion: "6.5.0"
MonoVersion: "6.12.0"
DotNetVersion2: "8.0.404"
Artifacts: ${{ github.workspace }}/artifacts/
Coverage: ${{ github.workspace }}/coverage/
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: "true"
Expand Down Expand Up @@ -38,28 +34,17 @@ jobs:
clean: "false"
fetch-depth: "0"

- name: Setup NuGet.exe
uses: nuget/setup-nuget@v1
with:
nuget-version: ${{ env.NuGetVersion }}

- name: 🔨 Use .NET Core SDKs
uses: actions/setup-dotnet@v3
with:
dotnet-version: |
${{ env.DotNetVersion4 }}
${{ env.DotNetVersion3 }}
${{ env.DotNetVersion2 }}
${{ env.DotNetVersion }}

- name: 🎁 dotnet tool restore
run: |
dotnet tool restore

- name: 🎁 nuget install
run: |
nuget install tools/packages.config -ExcludeVersion -OutputDirectory tools

- name: 🍰 Run Cake
uses: nick-invision/retry@v2
with:
Expand All @@ -68,7 +53,7 @@ jobs:
max_attempts: 3
retry_on: error
command: |
dotnet cake --configuration=Release --verbosity=Verbose --target=Test --test-project="$TEST_PROJECT"
dotnet cake --configuration=Release --verbosity=Verbose --target=Test --test-project="$TEST_PROJECT" --use-dotnet-test
env:
TEST_PROJECT: ${{ matrix.testProjects }}

Expand Down
27 changes: 1 addition & 26 deletions .pipelines/init.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,8 @@
parameters:
# Configuration: Release
Verbosity: Normal
DotNetVersion: "8.0.303"
DotNetVersion: "8.0.404"
CakeVersion: "1.1.0"
NuGetVersion: "5.7.0"
MonoVersion: ""
steps:
- task: DownloadBuildArtifacts@0
displayName: "Download GitVersion Variables"
Expand Down Expand Up @@ -32,26 +30,3 @@ steps:
workingDirectory: "$(Build.ArtifactStagingDirectory)"
env:
CakeVersion: ${{ parameters.CakeVersion }}
- task: NuGetToolInstaller@0
displayName: "Get NuGet"
inputs:
versionSpec: ${{ parameters.NuGetVersion }}
- task: NuGetCommand@2
displayName: "Cake restore packages.config"
inputs:
command: custom
feedsToUse: config
arguments: install tools/packages.config -ExcludeVersion -OutputDirectory tools
- ${{ if ne(parameters.MonoVersion, '') }}:
- script: |
curl -o mono.pkg https://download.mono-project.com/archive/$MONO_VERSION/macos-10-universal/MonoFramework-MDK-$MONO_VERSION.182.macos10.xamarin.universal.pkg
sudo installer -pkg mono.pkg -target /
sudo cp -rf /Library/Frameworks/Mono.framework/Versions/$MONO_VERSION/ /Library/Frameworks/Mono.framework/Versions/Current/
MONOPREFIX=/Library/Frameworks/Mono.framework/Versions/$MONO_VERSION
echo "##vso[task.setvariable variable=DYLD_FALLBACK_LIBRARY_PATH;]$MONOPREFIX/lib:/lib:/usr/lib:$DYLD_LIBRARY_FALLBACK_PATH"
echo "##vso[task.setvariable variable=PKG_CONFIG_PATH;]$MONOPREFIX/lib/pkgconfig:$MONOPREFIX/share/pkgconfig:$PKG_CONFIG_PATH"
echo "##vso[task.setvariable variable=PATH;]$MONOPREFIX/bin:$PATH"
env:
MONO_VERSION: ${{ parameters.MonoVersion }}
displayName: Use Mono ${{ parameters.MonoVersion }}
failOnStderr: false
52 changes: 18 additions & 34 deletions BUILD.md
Original file line number Diff line number Diff line change
@@ -1,25 +1,9 @@
# Requirements

## Windows

In order to build OmniSharp, the [.NET 4.7.2 targeting pack](https://dotnet.microsoft.com/download/dotnet-framework/thank-you/net472-developer-pack-offline-installer) must be installed if it isn't already.

## macOS

**Mono 6.6.0** or greater is required. You can install this using the latest [.pkg](http://www.mono-project.com/download/#download-mac) or install it view [Homebrew](https://brew.sh/):

```
brew update
brew install mono
brew install homebrew/cask/mono-mdk
```

## Linux

Because OmniSharp uses the .NET Core SDK as part of the build, not all Linux distros are supported. A good rule of thumb is to check the list [here](https://docs.microsoft.com/dotnet/core/install/dependencies?pivots=os-linux) to see if your particular distro is supported.

**Mono 6.6.0** or greater is required. Each distro or derivative has its own set of instructions for installing Mono which you can find [here](http://www.mono-project.com/download/#download-lin). Be sure to install `msbuild` as well, which may be a separate package.

# Usage

Run `build.(ps1|sh)` with the desired set of arguments (see below for options).
Expand All @@ -30,21 +14,21 @@ All build related activites should be encapsulated in this file for cross-platfo

Note: The arguments below should prefixed with a single hyphen on Windows (PowerShell-style) and a double-hyphen on OSX/Linux.

`-target TargetName`: The name of the build task/target to execute (see below for listing and details).
Defaults to `Default`.
`-target TargetName`: The name of the build task/target to execute (see below for listing and details).
Defaults to `Default`.

`-configuration (Release|Debug)`: The configuration to build.
Defaults to `Debug`.
`-configuration (Release|Debug)`: The configuration to build.
Defaults to `Debug`.

`-test-configuration (Release|Debug)`: The configuration to use for the unit tests.
Defaults to `Debug`.
`-test-configuration (Release|Debug)`: The configuration to use for the unit tests.
Defaults to `Debug`.

`-install-path Path`: Path used for the **Install** target.
Defaults to `(%USERPROFILE%|$HOME)/.omnisharp`
`-install-path Path`: Path used for the **Install** target.
Defaults to `(%USERPROFILE%|$HOME)/.omnisharp`

`-publish-all`: Publishes all platforms for the current OS. On Windows, specifying this argument would produce win7-x86, win7-x64, and win10-arm64 builds. On OSX/Linux, this argument causes osx, linux-x86, linux-x64, linux-musl-x64, linux-musl-arm64 and linux-arm64 builds to be published.
`-publish-all`: Publishes all platforms for the current OS. On Windows, specifying this argument would produce win-x86, win-x64, and win-arm64 builds. On OSX/Linux, this argument causes osx, linux-x86, linux-x64, linux-musl-x64, linux-musl-arm64 and linux-arm64 builds to be published.

`-archive`: Enable the generation of publishable archives after a build.
`-archive`: Enable the generation of publishable archives after a build.

Note: On macOS/Linux, be sure to pass the arguments above with a double hyphen! (e.g. `--target TargetName`).

Expand All @@ -65,18 +49,18 @@ Note: On macOS/Linux, be sure to pass the arguments above with a double hyphen!
A number of build-related options, including folder names for different entities. Interesting options:

**DotNetInstallScriptURL**: The URL where the .NET SDK install script is located.
Can be used to pin to a specific script version, if a breaking change occurs.
Can be used to pin to a specific script version, if a breaking change occurs.

**DotNetChannel**: The .NET Core SDK channel used for retreiving the tools.

**DotNetVersion**: The .NET Core SDK version used for the build. Can be used to pin to a specific version.
Using the string `Latest` will retrieve the latest version.
Using the string `Latest` will retrieve the latest version.

# Artifacts generated

* OmniSharp binaries for specified runtimes `artifacts/publish/OmniSharp/{platform}/`
* Scripts to run OmniSharp at `scripts/OmniSharp(.Core)(.cmd)`
* These scripts are updated for every build and every install.
* The scripts point to the installed binary after and install, otherwise just the build folder (reset if a new build occurs without an install).
* Test logs in `artifacts/logs`
* Archived binaries in `artifacts/package` (only if `-archive` used on command line)
- OmniSharp binaries for specified runtimes `artifacts/publish/OmniSharp/{platform}/`
- Scripts to run OmniSharp at `scripts/OmniSharp(.Core)(.cmd)`
- These scripts are updated for every build and every install.
- The scripts point to the installed binary after and install, otherwise just the build folder (reset if a new build occurs without an install).
- Test logs in `artifacts/logs`
- Archived binaries in `artifacts/package` (only if `-archive` used on command line)
11 changes: 1 addition & 10 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,13 @@
<MicrosoftExtensionPackageVersion>9.0.0</MicrosoftExtensionPackageVersion>
<MicrosoftBaseCommonLibraryVersion>9.0.0</MicrosoftBaseCommonLibraryVersion>
<MicrosoftTestPackageVersion>17.8.0</MicrosoftTestPackageVersion>
<MSBuildPackageVersion>17.3.2</MSBuildPackageVersion>
<MSBuildPackageVersion>17.8.3</MSBuildPackageVersion>
<NuGetPackageVersion>6.14.0-preview.1.45</NuGetPackageVersion>
<RoslynPackageVersion>4.14.0-3.25168.13</RoslynPackageVersion>
<XunitPackageVersion>2.6.1</XunitPackageVersion>
</PropertyGroup>

<ItemGroup>
<PackageVersion Include="BenchmarkDotNet" Version="0.13.10" />
<PackageVersion Include="BenchmarkDotNet.Diagnostics.Windows" Version="0.13.10" />

<PackageVersion Include="Cake.Scripting.Transport" Version="0.16.0" />

<PackageVersion Include="DiffPlex" Version="1.7.2" />
Expand Down Expand Up @@ -102,10 +99,4 @@
<ItemGroup>
<PackageVersion Include="Microsoft.SourceLink.GitHub" Version="8.0.0" PrivateAssets="All" />
</ItemGroup>
<ItemGroup Condition="'$(TargetFramework)' == 'net472'">
<PackageVersion Include="Microsoft.AspNetCore.Diagnostics" Version="2.2.0" />
<PackageVersion Include="Microsoft.AspNetCore.Hosting" Version="2.2.0" />
<PackageVersion Include="Microsoft.AspNetCore.Http.Features" Version="2.2.0" />
<PackageVersion Include="Microsoft.AspNetCore.Server.Kestrel" Version="2.2.0" />
</ItemGroup>
</Project>
18 changes: 10 additions & 8 deletions NuGet.Config
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,20 @@
<packageSources>
<clear />
<add key="NuGet" value="https://api.nuget.org/v3/index.json" />
<add key="dotnet-tools" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-tools/nuget/v3/index.json" />
<add key="dotnet6" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet6/nuget/v3/index.json" />
<add key="dotnet6-transport" value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet6-transport/nuget/v3/index.json" />
<add key="vs-impl" value="https://pkgs.dev.azure.com/azure-public/vside/_packaging/vs-impl/nuget/v3/index.json" />
<add key="dotnet-tools"
value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-tools/nuget/v3/index.json" />
<add key="dotnet8"
value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet8/nuget/v3/index.json" />
<add key="dotnet8-transport"
value="https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet8-transport/nuget/v3/index.json" />
<add key="vs-impl"
value="https://pkgs.dev.azure.com/azure-public/vside/_packaging/vs-impl/nuget/v3/index.json" />
<add key="OmniSharp" value="https://www.myget.org/F/omnisharp/api/v3/index.json" />
</packageSources>
<packageSourceMapping>
<clear />
<packageSource key="NuGet">
<package pattern="Antlr4.*" />
<package pattern="BenchmarkDotNet" />
<package pattern="BenchmarkDotNet.*" />
<package pattern="Cake.*" />
<package pattern="DiffPlex" />
<package pattern="Dotnet.Script.*" />
Expand Down Expand Up @@ -50,11 +52,11 @@
<package pattern="microsoft.*" />
<package pattern="NuGet.*" />
</packageSource>
<packageSource key="dotnet6">
<packageSource key="dotnet8">
<package pattern="microsoft.*" />
</packageSource>
</packageSourceMapping>
<disabledPackageSources>
<clear />
</disabledPackageSources>
</configuration>
</configuration>
Loading
Loading