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

#8819: Compile workflow should run at least one of the SpecFlow tests #8820

Merged
merged 4 commits into from
Dec 7, 2024
Merged
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
25 changes: 15 additions & 10 deletions .github/workflows/compile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@ jobs:
shell: pwsh
runs-on: windows-latest
steps:
- name: Clone repository
- name: Clone Repository
uses: actions/[email protected]

- name: Restore NuGet packages
- name: Restore NuGet Packages
run: nuget restore src/Orchard.sln

- name: Add msbuild to PATH
- name: Add MSBuild to PATH
uses: microsoft/setup-msbuild@v2

- name: Compile
Expand All @@ -31,14 +31,19 @@ jobs:
- name: Test
run: msbuild Orchard.proj /m /v:minimal /t:Test

- name: Run Orchard setup
- name: Test Setup with SpecFlow
run: |
$nunitConsole = (Get-ChildItem -Path 'src/packages' -Recurse -Filter 'nunit-console.exe' | Select-Object -Last 1).FullName
& $nunitConsole 'build/Compile/Orchard.Specs.dll' /xml='build/Orchard.Specs.xml' /run=Orchard.Specs.SetupFeature.RootAndSetupFolderShowsSetupScreenAndFormValuesAreValidated

- name: Run Orchard Setup with Orchard.exe
run: |
$commandFile = 'src/Orchard.Web/bin/setup-commands.txt'
New-Item -Path $commandFile -ItemType File -Force
Set-Content -Path $commandFile -Value 'setup /SiteName:Orchard /AdminUsername:admin /AdminPassword:Password1! /DatabaseProvider:SqlCe /Recipe:Default'
& 'src/Orchard.Web/bin/Orchard.exe' @$commandFile

- name: Run code generation
- name: Run Code Generation
run: |
$commandFile = 'src/Orchard.Web/bin/codegen-commands.txt'
New-Item -Path $commandFile -ItemType File -Force
Expand All @@ -50,25 +55,25 @@ jobs:
'@
& 'src/Orchard.Web/bin/Orchard.exe' @$commandFile

- name: Compile with generated projects
- name: Compile Again with Generated Projects
run: msbuild Orchard.proj /m /v:minimal /t:Compile /p:TreatWarningsAsErrors=true -WarnAsError /NoWarn:CS2008

compile-node:
name: Compile client-side assets
name: Compile Client-side Assets
defaults:
run:
shell: pwsh
runs-on: windows-latest
steps:
- name: Clone repository
- name: Clone Repository
uses: actions/[email protected]

- name: Setup NodeJS
uses: actions/[email protected]
with:
node-version: '7'

- name: Setup NPM packages
- name: Setup NPM Packages
working-directory: ./src
run: |
npm install --loglevel warn
Expand All @@ -77,7 +82,7 @@ jobs:
$gulpVersion = (Get-Content Package.json -Raw | ConvertFrom-Json).devDependencies.gulp
Start-Process npm -NoNewWindow -Wait -ArgumentList "install gulp@$gulpVersion -g --loglevel warn"

- name: Rebuild client-side assets
- name: Rebuild Client-side Assets
working-directory: ./src
run: |
gulp rebuild
Expand Down
2 changes: 1 addition & 1 deletion src/Orchard.Specs/Hosting/Orchard.Web/Web.config
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-12.0.0.0" newVersion="12.0.0.0" />
<bindingRedirect oldVersion="0.0.0.0-13.0.0.0" newVersion="13.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="NHibernate" publicKeyToken="aa95f207798dfdb4" culture="neutral" />
Expand Down