Skip to content

Commit

Permalink
Move test projects from src/ to tests/ (#11357)
Browse files Browse the repository at this point in the history
* Update gitignore

* Move csproj

* Update project references

* Update solutions

* Update build scripts

* Tests used to share editorconfig with projects in src

* Fix broken tests.

* Stop copying around .editorconfig

merged root one with linting

* csharp_style_expression_bodied -> suggestion

* Move StyleCop rulesets to matching directories and update shared build properties

* Remove legacy build files, update NuGet.cofig and solution files

* Restore myget source

* Clean up .gitignore

* Update .gitignore

* Move new test classes to tests after merge

* Gitignore + nuget config

* Move new test

Co-authored-by: Ronald Barendse <[email protected]>
  • Loading branch information
Paul Johnson and ronaldbarendse authored Oct 18, 2021
1 parent c005673 commit 00133e8
Show file tree
Hide file tree
Showing 752 changed files with 651 additions and 1,845 deletions.
462 changes: 436 additions & 26 deletions .editorconfig

Large diffs are not rendered by default.

145 changes: 46 additions & 99 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@
.DS_Store
._.DS_Store
.vs/
/local/
.idea/

# Build directories
[Bb]in/
[Db]ebug*/
[Rr]elease*/
obj/
[Oo]bj/
[Db]ebug/
[Rr]elease/

# Tools
_ReSharper*/
Expand All @@ -35,122 +35,69 @@ _NCrunch_*/
*.ncrunchproject
*.crunchsolution.cache
tools/NDepend/

[Tt]est[Rr]esult*
[Bb]uild[Ll]og.*
*.[Pp]ublish.xml
[sS]ource
[sS]andbox
umbraco.config
App_Data/TEMP/*
[Uu]mbraco/[Pp]resentation/[Uu]mbraco/[Pp]lugins/*
[Uu]mbraco/[Pp]resentation/[Uu]ser[Cc]ontrols/*
[Uu]mbraco/[Pp]resentation/[Ss]cripts/*
[Uu]mbraco/[Pp]resentation/[Ff]onts/*
[Uu]mbraco/[Pp]resentation/[Cc]ss/*

src/Umbraco.Tests/App_Data/*

umbraco/presentation/umbraco/plugins/uComponents/uComponentsInstaller.ascx
umbraco/presentation/packages/uComponents/MultiNodePicker/CustomTreeService.asmx

src/Umbraco.Tests/config/applications.config
src/Umbraco.Tests/config/trees.config
src/Umbraco.Tests/config/404handlers.config
src/Umbraco.Tests/[Cc]onfig/umbracoSettings.config
src/packages/
src/packages/repositories.config

*.transformed

node_modules
lib-bower

src/Umbraco.Web.UI.Client/[Bb]uild/*
src/Umbraco.Web.UI.Client/[Bb]uild/[Bb]elle/

src/Umbraco.Web.UI.Client/src/[Ll]ess/*.css
src/Umbraco.Web.UI.Client/vwd.webinfo

src/*.psess
src/*.vspx

*.psess
*.vspx
NDependOut/*
QueryResult.htm

build/ApiDocs/*
build/ApiDocs/Output/*
src/Umbraco.Web.UI.Client/bower_components/*
tools/docfx/*

# Ignore rule for clearing out Belle (avoid rebuilding all the time)
preserve.belle

# Ignore rule for output of generated documentation files from grunt docserve
src/Umbraco.Web.UI.Docs/api
src/Umbraco.Web.UI.Docs/package-lock.json
src/*.boltdata/
src/umbraco.sln.ide/*
src/.vs/

src/Umbraco.Tests/[Mm]edia
tools/docfx/*
apidocs/_site/*
src/*/project.lock.json
src/.idea/*

apidocs/api/*
build/docs.zip
build/ui-docs.zip
build/csharp-docs.zip
src/packages/
src/PrecompiledWeb/*

# Build
build.out/
build.tmp/
build/hooks/
build/temp/

# Acceptance tests
cypress.env.json
/src/Umbraco.Tests.AcceptanceTest/cypress/support/chainable.ts
/src/Umbraco.Tests.AcceptanceTest/package-lock.json
/src/Umbraco.Tests.AcceptanceTest/cypress/videos/
/src/Umbraco.Tests.AcceptanceTest/cypress/screenshots/

/src/Umbraco.Web.UI.Client/TESTS-*.xml
/src/ApiDocs/api/*
/src/Umbraco.Web.UI.Client/package-lock.json
/src/Umbraco.Web.UI/wwwroot/Media/*
/src/Umbraco.Tests.Integration/App_Data/*
/src/Umbraco.Tests.Integration/TEMP/*
/src/Umbraco.Web.UI/wwwroot/[Uu]mbraco/assets/*
/src/Umbraco.Web.UI/wwwroot/[Uu]mbraco/js/*
/src/Umbraco.Web.UI/wwwroot/[Uu]mbraco/lib/*
/src/Umbraco.Web.UI/wwwroot/[Uu]mbraco/views/*
/src/Umbraco.Web.UI/wwwroot/App_Data/TEMP/*
/src/Umbraco.Web.UI/App_Data/Logs/*
/src/Umbraco.Web.UI/App_Data/TEMP/TypesCache/*
/src/Umbraco.Web.UI/App_Data/TEMP/*
/src/Umbraco.Web.UI/App_Data/Smidge/Cache/*
/src/Umbraco.Web.UI/[Uu]mbraco/[Ll]ogs
/src/Umbraco.Web.UI/[Uu]mbraco/[Dd]ata/*
/src/Umbraco.Web.UI/[Uu]mbraco/[Mm]odels/*
/src/Umbraco.Web.UI/[Vv]iews/*.vbhtml
/src/Umbraco.Web.UI/appsettings.json
/src/Umbraco.Web.UI/appsettings.Development.json
/src/Umbraco.Web.UI/appsettings.Local.json


src/Umbraco.Tests.Integration/umbraco/Data/
src/Umbraco.Tests.Integration/umbraco/logs/

src/Umbraco.Tests.Integration/Views/

src/Umbraco.Tests/TEMP/

src/Umbraco.Tests.UnitTests/umbraco/Data/TEMP/
src/Umbraco.Tests.Integration.SqlCe/umbraco/Data/TEMP/
src/Umbraco.Tests.Integration.SqlCe/DatabaseContextTests.sdf
# Build output
build/docs.zip
build/ui-docs.zip
build/csharp-docs.zip
build/ApiDocs/*
build/ApiDocs/Output/*
src/ApiDocs/api/*

# Environment specific data
src/Umbraco.Web.UI.Client/[Bb]uild/*
src/Umbraco.Web.UI.Client/[Bb]uild/[Bb]elle/
src/Umbraco.Web.UI.Client/src/[Ll]ess/*.css
src/Umbraco.Web.UI.Client/TESTS-*.xml
src/Umbraco.Web.UI/[Uu]mbraco/[Dd]ata/*
src/Umbraco.Web.UI/[Uu]mbraco/[Ll]ogs
src/Umbraco.Web.UI/[Uu]mbraco/[Mm]odels/*
src/Umbraco.Web.UI/appsettings.Development.json
src/Umbraco.Web.UI/appsettings.json
src/Umbraco.Web.UI/appsettings.Local.json
src/Umbraco.Web.UI/wwwroot/[Uu]mbraco/assets/*
src/Umbraco.Web.UI/wwwroot/[Uu]mbraco/js/*
src/Umbraco.Web.UI/wwwroot/[Uu]mbraco/lib/*
src/Umbraco.Web.UI/wwwroot/[Uu]mbraco/views/*
src/Umbraco.Web.UI/wwwroot/Media/*

# Tests
cypress.env.json
tests/Umbraco.Tests.AcceptanceTest/cypress/screenshots/
tests/Umbraco.Tests.AcceptanceTest/cypress/support/chainable.ts
tests/Umbraco.Tests.AcceptanceTest/cypress/videos/
tests/Umbraco.Tests.AcceptanceTest/package-lock.json
tests/Umbraco.Tests.Integration.SqlCe/DatabaseContextTests.sdf
tests/Umbraco.Tests.Integration.SqlCe/umbraco/Data/TEMP/
tests/Umbraco.Tests.Integration/TEMP/*
tests/Umbraco.Tests.Integration/umbraco/Data/
tests/Umbraco.Tests.Integration/umbraco/logs/
tests/Umbraco.Tests.Integration/Views/
tests/Umbraco.Tests.UnitTests/umbraco/Data/TEMP/

# Ignore auto-generated schema
src/Umbraco.Web.UI/umbraco/config/appsettings-schema.json
22 changes: 6 additions & 16 deletions Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,23 +1,13 @@
<?xml version="1.0" encoding="utf-8"?>
<Project>

<!-- Package references and additional files which are consumed by all projects -->
<ItemGroup>
<PackageReference Include="StyleCop.Analyzers" IsImplicitlyDefined="true" />
<AdditionalFiles Include="$(MSBuildThisFileDirectory)linting\stylecop.json" />
<PackageReference Include="StyleCop.Analyzers" Version="1.1.118" PrivateAssets="all" IsImplicitlyDefined="true" />
<AdditionalFiles Include="$(MSBuildThisFileDirectory)stylecop.json" Link="stylecop.json" />
</ItemGroup>

<Choose>
<When Condition="$([System.Text.RegularExpressions.Regex]::IsMatch($(MSBuildProjectFile), 'Tests'))">
<PropertyGroup>
<CodeAnalysisRuleSet>$(MSBuildThisFileDirectory)linting\codeanalysis.tests.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
</When>
<Otherwise>
<PropertyGroup>
<CodeAnalysisRuleSet>$(MSBuildThisFileDirectory)linting\codeanalysis.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
</Otherwise>
</Choose>

<!-- Specify rule set for all projects -->
<PropertyGroup>
<CodeAnalysisRuleSet>$(MSBuildThisFileDirectory)codeanalysis.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
</Project>
26 changes: 0 additions & 26 deletions Directory.Build.targets

This file was deleted.

18 changes: 5 additions & 13 deletions NuGet.Config
Original file line number Diff line number Diff line change
@@ -1,15 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<!--
this is Umbraco's NuGet configuration,
content of this file is merged with the system-wide configuration,
at %APPDATA%\NuGet\NuGet.config
-->
<packageSources>
<clear />
<add key="nuget" value="https://api.nuget.org/v3/index.json" />
<add key="UmbracoCoreMyGet" value="https://www.myget.org/F/umbracocore/api/v3/index.json" />
<add key="SmidgeAppVeyor" value="https://ci.appveyor.com/nuget/smidge" />
<add key="Umbraco Nightly" value="https://www.myget.org/F/umbraconightly/api/v3/index.json" />
</packageSources>
<packageSources>
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" protocolVersion="3" />
<add key="Umbraco Nightly" value="https://www.myget.org/F/umbraconightly/api/v3/index.json" protocolVersion="3" />
</packageSources>
</configuration>
59 changes: 0 additions & 59 deletions build/Azure/azuregalleryrelease.ps1

This file was deleted.

6 changes: 1 addition & 5 deletions build/NuSpecs/UmbracoCms.StaticAssets.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,7 @@
<file src="$BuildTmp$\WebApp\wwwroot\umbraco\**\*.*" target="content\wwwroot\umbraco" />
<file src="$BuildTmp$\WebApp\umbraco\**\*.*" target="content\umbraco" />

<!-- Readme -->
<file src="tools\Readme.txt" target="Readme.txt" />
<file src="tools\ReadmeUpgrade.txt" target="ReadmeUpgrade.txt" />

<!-- UmbracoCms props and targets used to copy the content into the solution -->
<file src="build\**" target="buildTransitive\" />
<file src="buildTransitive\**" target="buildTransitive\" />
</files>
</package>
8 changes: 0 additions & 8 deletions build/NuSpecs/tools/ClientDependency.config.install.xdt

This file was deleted.

27 changes: 0 additions & 27 deletions build/NuSpecs/tools/Readme.txt

This file was deleted.

26 changes: 0 additions & 26 deletions build/NuSpecs/tools/ReadmeUpgrade.txt

This file was deleted.

Loading

0 comments on commit 00133e8

Please sign in to comment.