diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.controller.js b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.controller.js
index 5e73755593..f0b89a095f 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.controller.js
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.controller.js
@@ -20,7 +20,7 @@
var unsubscribe = [];
- var vm = this;
+ const vm = this;
vm.openBlock = null;
function onInit() {
@@ -30,11 +30,10 @@
}
loadElementTypes();
-
}
function loadElementTypes() {
- return elementTypeResource.getAll().then(function (elementTypes) {
+ return elementTypeResource.getAll().then(elementTypes => {
vm.elementTypes = elementTypes;
});
}
@@ -47,24 +46,32 @@
}
}
}
+
unsubscribe.push(eventsService.on("editors.documentType.saved", updateUsedElementTypes));
- vm.requestRemoveBlockByIndex = function (index) {
- localizationService.localizeMany(["general_delete", "blockEditor_confirmDeleteBlockTypeMessage", "blockEditor_confirmDeleteBlockTypeNotice"]).then(function (data) {
+ vm.requestRemoveBlockByIndex = function (index, event) {
+
+ const labelKeys = [
+ "general_delete",
+ "blockEditor_confirmDeleteBlockTypeMessage",
+ "blockEditor_confirmDeleteBlockTypeNotice"
+ ];
+
+ localizationService.localizeMany(labelKeys).then(data => {
var contentElementType = vm.getElementTypeByKey($scope.model.value[index].contentElementTypeKey);
overlayService.confirmDelete({
title: data[0],
content: localizationService.tokenReplace(data[1], [contentElementType ? contentElementType.name : "(Unavailable ElementType)"]),
confirmMessage: data[2],
- close: function () {
- overlayService.close();
- },
- submit: function () {
+ submit: () => {
vm.removeBlockByIndex(index);
overlayService.close();
- }
+ },
+ close: overlayService.close()
});
});
+
+ event.stopPropagation();
}
vm.removeBlockByIndex = function (index) {
@@ -78,7 +85,6 @@
placeholder: 'umb-block-card --sortable-placeholder'
};
-
vm.getAvailableElementTypes = function () {
return vm.elementTypes.filter(function (type) {
return !$scope.model.value.find(function (entry) {
@@ -89,15 +95,13 @@
vm.getElementTypeByKey = function(key) {
if (vm.elementTypes) {
- return vm.elementTypes.find(function (type) {
- return type.key === key;
- }) || null;
+ return vm.elementTypes.find(type => type.key === key) || null;
}
};
vm.openAddDialog = function () {
- localizationService.localize("blockEditor_headlineCreateBlock").then(function(localizedTitle) {
+ localizationService.localize("blockEditor_headlineCreateBlock").then(localizedTitle => {
const contentTypePicker = {
title: localizedTitle,
@@ -108,10 +112,9 @@
filter: function (node) {
if (node.metaData.isElement === true) {
var key = udiService.getKey(node.udi);
+
// If a Block with this ElementType as content already exists, we will emit it as a posible option.
- return $scope.model.value.find(function (entry) {
- return key === entry.contentElementTypeKey;
- });
+ return $scope.model.value.find(entry => entry.contentElementTypeKey === key);
}
return true;
},
@@ -138,8 +141,8 @@
}
]
};
+
editorService.treePicker(contentTypePicker);
-
});
};
@@ -151,9 +154,10 @@
isElement: true,
noTemplate: true,
submit: function (model) {
- loadElementTypes().then( function () {
+ loadElementTypes().then(() => {
callback(model.documentTypeKey);
});
+
editorService.close();
},
close: function () {
@@ -165,60 +169,66 @@
vm.addBlockFromElementTypeKey = function(key) {
- var blockType = {
- "contentElementTypeKey": key,
- "settingsElementTypeKey": null,
- "labelTemplate": "",
- "view": null,
- "stylesheet": null,
- "editorSize": "medium",
- "iconColor": null,
- "backgroundColor": null,
- "thumbnail": null
+ const blockType = {
+ contentElementTypeKey: key,
+ settingsElementTypeKey: null,
+ labelTemplate: "",
+ view: null,
+ stylesheet: null,
+ editorSize: "medium",
+ iconColor: null,
+ backgroundColor: null,
+ thumbnail: null
};
$scope.model.value.push(blockType);
vm.openBlockOverlay(blockType);
-
};
-
-
-
-
vm.openBlockOverlay = function (block) {
var elementType = vm.getElementTypeByKey(block.contentElementTypeKey);
- if(elementType) {
- localizationService.localize("blockEditor_blockConfigurationOverlayTitle", [elementType.name]).then(function (data) {
+ if (elementType) {
+
+ let clonedBlockData = Utilities.copy(block);
+ vm.openBlock = block;
- var clonedBlockData = Utilities.copy(block);
- vm.openBlock = block;
-
- var overlayModel = {
- block: clonedBlockData,
- title: data,
- view: "views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.overlay.html",
- size: "small",
- submit: function(overlayModel) {
- loadElementTypes()// lets load elementType again, to ensure we are up to date.
- TransferProperties(overlayModel.block, block);// transfer properties back to block object. (Doing this cause we dont know if block object is added to model jet, therefor we cant use index or replace the object.)
- overlayModel.close();
- },
- close: function() {
- editorService.close();
- vm.openBlock = null;
- }
- };
+ const overlayModel = {
+ block: clonedBlockData,
+
+ view: "views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.overlay.html",
+ size: "small",
+ submit: function(overlayModel) {
+ loadElementTypes()// lets load elementType again, to ensure we are up to date.
+ TransferProperties(overlayModel.block, block);// transfer properties back to block object. (Doing this cause we dont know if block object is added to model jet, therefor we cant use index or replace the object.)
+ overlayModel.close();
+ },
+ close: function() {
+ editorService.close();
+ vm.openBlock = null;
+ }
+ };
+ localizationService.localize("blockEditor_blockConfigurationOverlayTitle", [elementType.name]).then(data => {
+ overlayModel.title = data,
+
// open property settings editor
editorService.open(overlayModel);
-
});
} else {
- alert("Cannot be edited cause ElementType does not exist.");
+
+ const overlay = {
+ close: () => {
+ overlayService.close()
+ }
+ };
+
+ localizationService.localize("blockEditor_elementTypeDoesNotExist").then(data => {
+ overlay.content = data;
+ overlayService.open(overlay);
+ });
}
};
diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.html b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.html
index de6a409415..3172219434 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.html
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.html
@@ -1,7 +1,7 @@
diff --git a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.less b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.less
index 878f6a8ef8..afb4316ce8 100644
--- a/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.less
+++ b/src/Umbraco.Web.UI.Client/src/views/propertyeditors/blocklist/prevalue/blocklist.blockconfiguration.less
@@ -18,11 +18,11 @@
padding: 5px 15px;
box-sizing: border-box;
font-weight: bold;
- }
-
- .__add-button:hover {
- color: @ui-action-discreet-type-hover;
- border-color: @ui-action-discreet-border-hover;
+
+ &:hover {
+ color: @ui-action-discreet-type-hover;
+ border-color: @ui-action-discreet-border-hover;
+ }
}
}
diff --git a/src/Umbraco.Web.UI.Docs/gulpfile.js b/src/Umbraco.Web.UI.Docs/gulpfile.js
index 1aff4f7e35..2117b7a176 100644
--- a/src/Umbraco.Web.UI.Docs/gulpfile.js
+++ b/src/Umbraco.Web.UI.Docs/gulpfile.js
@@ -18,7 +18,7 @@ gulp.task('docs', [], function (cb) {
var options = {
html5Mode: false,
startPage: '/api',
- title: "Umbraco 9 Backoffice UI API Documentation",
+ title: "Umbraco 10 Backoffice UI API Documentation",
dest: './api',
styles: ['./umb-docs.css'],
image: "https://our.umbraco.com/assets/images/logo.svg"
diff --git a/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj b/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj
index 88b76d1af0..54ab69b37e 100644
--- a/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj
+++ b/src/Umbraco.Web.UI/Umbraco.Web.UI.csproj
@@ -5,8 +5,6 @@
Umbraco.Cms.Web.UI
-
-
bin/Release/Umbraco.Web.UI.xml
@@ -14,23 +12,10 @@
true
-
+
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
@@ -56,7 +41,8 @@
- $(ProjectDir)umbraco/config/appsettings-schema.json
+ $(ProjectDir)appsettings-schema.json
+ $(ProjectDir)../JsonSchema/JsonSchema.csproj
@@ -73,7 +59,8 @@
-
+
+
diff --git a/src/Umbraco.Web.UI/appsettings.Development.template.json b/src/Umbraco.Web.UI/appsettings.Development.template.json
index 9cac2c3dd9..33c5dd2fae 100644
--- a/src/Umbraco.Web.UI/appsettings.Development.template.json
+++ b/src/Umbraco.Web.UI/appsettings.Development.template.json
@@ -1,5 +1,5 @@
{
- "$schema" : "./umbraco/config/appsettings-schema.json",
+ "$schema" : "./appsettings-schema.json",
"Serilog": {
"MinimumLevel": {
"Default": "Information",
diff --git a/src/Umbraco.Web.UI/appsettings.template.json b/src/Umbraco.Web.UI/appsettings.template.json
index 2a291c5bc6..ed03407c0b 100644
--- a/src/Umbraco.Web.UI/appsettings.template.json
+++ b/src/Umbraco.Web.UI/appsettings.template.json
@@ -1,5 +1,5 @@
{
- "$schema": "./umbraco/config/appsettings-schema.json",
+ "$schema": "./appsettings-schema.json",
"ConnectionStrings": {
"umbracoDbDSN": ""
},
diff --git a/templates/Umbraco.Templates.csproj b/templates/Umbraco.Templates.csproj
new file mode 100644
index 0000000000..182b220167
--- /dev/null
+++ b/templates/Umbraco.Templates.csproj
@@ -0,0 +1,47 @@
+
+
+
+
+
+ net6.0
+ Template
+ false
+ .
+ true
+ true
+ false
+ .
+ true
+ false
+
+
+
+
+
+
+
+ UmbracoProject\Program.cs
+ UmbracoProject
+
+
+ UmbracoProject\Startup.cs
+ UmbracoProject
+
+
+ UmbracoProject\Views\Partials\blocklist\%(RecursiveDir)%(Filename)%(Extension)
+ UmbracoProject\Views\Partials\blocklist
+
+
+ UmbracoProject\Views\Partials\grid\%(RecursiveDir)%(Filename)%(Extension)
+ UmbracoProject\Views\Partials\grid
+
+
+ UmbracoProject\Views\_ViewImports.cshtml
+ UmbracoProject\Views
+
+
+ UmbracoProject\wwwroot\favicon.ico
+ UmbracoProject\wwwroot
+
+
+
diff --git a/templates/Umbraco.Templates.nuspec b/templates/Umbraco.Templates.nuspec
deleted file mode 100644
index 7539d3a1f0..0000000000
--- a/templates/Umbraco.Templates.nuspec
+++ /dev/null
@@ -1,32 +0,0 @@
-
-
-
- Umbraco.Templates
- 1.0.0
- Umbraco HQ
- Umbraco HQ
- MIT
- https://umbraco.com/
- icon.png
- https://umbraco.com/dist/nuget/logo-small.png
- false
- Umbraco CMS templates for .NET Core Template Engine available through the dotnet CLI's new command
- en-US
- umbraco
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/templates/UmbracoProject/appsettings.Development.json b/templates/UmbracoProject/appsettings.Development.json
index 7567335326..d789f6cd32 100644
--- a/templates/UmbracoProject/appsettings.Development.json
+++ b/templates/UmbracoProject/appsettings.Development.json
@@ -1,5 +1,5 @@
{
- "$schema": "./umbraco/config/appsettings-schema.json",
+ "$schema": "./appsettings-schema.json",
"Serilog": {
"MinimumLevel": {
"Default": "Information"
diff --git a/templates/UmbracoProject/appsettings.json b/templates/UmbracoProject/appsettings.json
index 121e907020..5e866a77a3 100644
--- a/templates/UmbracoProject/appsettings.json
+++ b/templates/UmbracoProject/appsettings.json
@@ -1,5 +1,5 @@
{
- "$schema": "./umbraco/config/appsettings-schema.json",
+ "$schema": "./appsettings-schema.json",
"Serilog": {
"MinimumLevel": {
"Default": "Information",
diff --git a/tests/Umbraco.Tests.AcceptanceTest/cypress/integration/Packages/packages.ts b/tests/Umbraco.Tests.AcceptanceTest/cypress/integration/Packages/packages.ts
index f6ecdfc9f8..a83bbcd68f 100644
--- a/tests/Umbraco.Tests.AcceptanceTest/cypress/integration/Packages/packages.ts
+++ b/tests/Umbraco.Tests.AcceptanceTest/cypress/integration/Packages/packages.ts
@@ -34,7 +34,7 @@ context('Packages', () => {
mediaUdis: [],
mediaLoadChildNodes: false
}
- const url = "https://localhost:44331/umbraco/backoffice/umbracoapi/package/PostSavePackage";
+ const url = "/umbraco/backoffice/umbracoapi/package/PostSavePackage";
cy.umbracoApiRequest(url, 'POST', newPackage);
}
@@ -159,4 +159,4 @@ context('Packages', () => {
cy.umbracoEnsureDocumentTypeNameNotExists(rootDocTypeName);
cy.umbracoEnsurePackageNameNotExists(packageName);
});
-});
\ No newline at end of file
+});
diff --git a/tests/Umbraco.Tests.AcceptanceTest/misc/Directory.Build.props b/tests/Umbraco.Tests.AcceptanceTest/misc/Directory.Build.props
new file mode 100644
index 0000000000..65a0b30da2
--- /dev/null
+++ b/tests/Umbraco.Tests.AcceptanceTest/misc/Directory.Build.props
@@ -0,0 +1,2 @@
+
+
\ No newline at end of file
diff --git a/tests/Umbraco.Tests.AcceptanceTest/misc/nuget.config b/tests/Umbraco.Tests.AcceptanceTest/misc/nuget.config
new file mode 100644
index 0000000000..794b7dace7
--- /dev/null
+++ b/tests/Umbraco.Tests.AcceptanceTest/misc/nuget.config
@@ -0,0 +1,8 @@
+
+
+
+
+
+
+
+
diff --git a/tests/Umbraco.Tests.AcceptanceTest/misc/umbraco-linux.docker b/tests/Umbraco.Tests.AcceptanceTest/misc/umbraco-linux.docker
new file mode 100644
index 0000000000..b44e817fec
--- /dev/null
+++ b/tests/Umbraco.Tests.AcceptanceTest/misc/umbraco-linux.docker
@@ -0,0 +1,34 @@
+############################################
+## Build
+############################################
+
+FROM mcr.microsoft.com/dotnet/sdk:6.0.300 AS build
+
+WORKDIR /nupkg
+COPY nupkg .
+
+WORKDIR /build
+RUN dotnet new --install /nupkg/Umbraco.Templates.*.nupkg
+RUN dotnet new umbraco --name Cypress -o . --no-restore
+RUN dotnet restore -s /nupkg -s https://api.nuget.org/v3/index.json
+RUN dotnet publish --no-restore --configuration Release -o /dist
+
+############################################
+## Run
+############################################
+
+FROM mcr.microsoft.com/dotnet/aspnet:6.0.5 AS run
+
+WORKDIR /cypress
+COPY --from=build dist .
+
+ENV ASPNETCORE_URLS="http://0.0.0.0:5000"
+ENV Umbraco__CMS__Global__InstallMissingDatabase="true"
+ENV ConnectionStrings__umbracoDbDSN_ProviderName="Microsoft.Data.SQLite"
+ENV ConnectionStrings__umbracoDbDSN="Data Source=|DataDirectory|/Umbraco.sqlite.db;Cache=Shared;Foreign Keys=True;Pooling=True"
+ENV Umbraco__CMS__Unattended__InstallUnattended="true"
+ENV Umbraco__CMS__Unattended__UnattendedUserName="Cypress Test"
+ENV Umbraco__CMS__Unattended__UnattendedUserEmail="cypress@umbraco.com"
+ENV Umbraco__CMS__Unattended__UnattendedUserPassword="UmbracoAcceptance123!"
+
+CMD dotnet Cypress.dll
diff --git a/tests/Umbraco.Tests.Common/Extensions/StringExtensions.cs b/tests/Umbraco.Tests.Common/Extensions/StringExtensions.cs
new file mode 100644
index 0000000000..b5ce0b6a88
--- /dev/null
+++ b/tests/Umbraco.Tests.Common/Extensions/StringExtensions.cs
@@ -0,0 +1,11 @@
+namespace Umbraco.Cms.Tests.Common.Extensions;
+
+public static class StringExtensions
+{
+ public static string StripNewLines(this string input) =>
+ input.Replace("\r\n", string.Empty)
+ .Replace("\n", string.Empty);
+
+ public static string NormalizeNewLines(this string input) =>
+ input.Replace("\r\n", "\n");
+}
diff --git a/tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj b/tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj
index 3bf6907aa8..1954093f66 100644
--- a/tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj
+++ b/tests/Umbraco.Tests.Integration/Umbraco.Tests.Integration.csproj
@@ -7,6 +7,7 @@
Umbraco CMS Integration Tests
Contains helper classes for integration tests with Umbraco, including all internal integration tests.
true
+ true
diff --git a/tests/Umbraco.Tests.UnitTests/Umbraco.Core/ShortStringHelper/StylesheetHelperTests.cs b/tests/Umbraco.Tests.UnitTests/Umbraco.Core/ShortStringHelper/StylesheetHelperTests.cs
index f918251566..736e6c76a1 100644
--- a/tests/Umbraco.Tests.UnitTests/Umbraco.Core/ShortStringHelper/StylesheetHelperTests.cs
+++ b/tests/Umbraco.Tests.UnitTests/Umbraco.Core/ShortStringHelper/StylesheetHelperTests.cs
@@ -5,6 +5,7 @@ using System.Collections.Generic;
using System.Linq;
using NUnit.Framework;
using Umbraco.Cms.Core.Strings.Css;
+using Umbraco.Cms.Tests.Common.Extensions;
using Umbraco.Extensions;
namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Core.ShortStringHelper
@@ -175,7 +176,7 @@ world */p{font-size: 1em;}")]
/**umb_name:Test2*/
.test2 {
#font-color: green;
-}"), result);
+}").NormalizeNewLines(), result.NormalizeNewLines());
}
[Test]
@@ -204,7 +205,7 @@ world */p{font-size: 1em;}")]
Assert.AreEqual(".test", rules.First().Selector);
Assert.AreEqual(
@"font-color: red;
-margin: 1rem;", rules.First().Styles);
+margin: 1rem;".NormalizeNewLines(), rules.First().Styles.NormalizeNewLines());
Assert.AreEqual("Test2", rules.Last().Name);
Assert.AreEqual(".test2", rules.Last().Selector);
diff --git a/tests/Umbraco.Tests.UnitTests/Umbraco.PublishedCache.NuCache/SnapDictionaryTests.cs b/tests/Umbraco.Tests.UnitTests/Umbraco.PublishedCache.NuCache/SnapDictionaryTests.cs
index a0d3c9b9eb..2b65cf81ef 100644
--- a/tests/Umbraco.Tests.UnitTests/Umbraco.PublishedCache.NuCache/SnapDictionaryTests.cs
+++ b/tests/Umbraco.Tests.UnitTests/Umbraco.PublishedCache.NuCache/SnapDictionaryTests.cs
@@ -564,12 +564,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.PublishedCache.NuCache
GC.Collect();
await d.CollectAsync();
- // in Release mode, it works, but in Debug mode, the weak reference is still alive
- // and for some reason we need to do this to ensure it is collected
-#if DEBUG
GC.Collect();
await d.CollectAsync();
-#endif
Assert.AreEqual(1, d.SnapCount);
v2 = s2.Get(1);
@@ -611,12 +607,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.PublishedCache.NuCache
GC.Collect();
await d.CollectAsync();
- // in Release mode, it works, but in Debug mode, the weak reference is still alive
- // and for some reason we need to do this to ensure it is collected
-#if DEBUG
GC.Collect();
await d.CollectAsync();
-#endif
Assert.AreEqual(1, d.SnapCount);
v2 = s2.Get(1);
diff --git a/tests/Umbraco.Tests.UnitTests/Umbraco.Tests.UnitTests.csproj b/tests/Umbraco.Tests.UnitTests/Umbraco.Tests.UnitTests.csproj
index cce774aa04..70bf694128 100644
--- a/tests/Umbraco.Tests.UnitTests/Umbraco.Tests.UnitTests.csproj
+++ b/tests/Umbraco.Tests.UnitTests/Umbraco.Tests.UnitTests.csproj
@@ -5,6 +5,7 @@
net6.0
Umbraco.Cms.Tests.UnitTests
false
+ true
diff --git a/tests/Umbraco.Tests.UnitTests/Umbraco.Web.Common/Macros/MacroParserTests.cs b/tests/Umbraco.Tests.UnitTests/Umbraco.Web.Common/Macros/MacroParserTests.cs
index 7cfa722957..5e8ff67962 100644
--- a/tests/Umbraco.Tests.UnitTests/Umbraco.Web.Common/Macros/MacroParserTests.cs
+++ b/tests/Umbraco.Tests.UnitTests/Umbraco.Web.Common/Macros/MacroParserTests.cs
@@ -5,6 +5,7 @@ using System;
using System.Collections.Generic;
using NUnit.Framework;
using Umbraco.Cms.Infrastructure.Macros;
+using Umbraco.Cms.Tests.Common.Extensions;
using Umbraco.Cms.Tests.Common.TestHelpers;
namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Web.Common.Macros
@@ -35,8 +36,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Web.Common.Macros
Macro alias: My.Map.isCool eh[boy!]
-asdfasdf
".Replace(Environment.NewLine, string.Empty),
- result.Replace(Environment.NewLine, string.Empty));
+asdfasdf
".StripNewLines(),
+ result.StripNewLines());
}
[Test]
@@ -54,8 +55,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Web.Common.Macros
Macro alias: Map
-asdfasdf
".Replace(Environment.NewLine, string.Empty),
- result.Replace(Environment.NewLine, string.Empty));
+asdfasdf
".StripNewLines(),
+ result.StripNewLines());
}
[Test]
@@ -73,8 +74,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Web.Common.Macros
Macro alias: Map
-asdfasdf
".Replace(Environment.NewLine, string.Empty),
- result.Replace(Environment.NewLine, string.Empty));
+asdfasdf
".StripNewLines(),
+ result.StripNewLines());
}
[Test]
@@ -92,8 +93,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Web.Common.Macros
Macro alias: Map
-asdfasdf
".Replace(Environment.NewLine, string.Empty),
- result.Replace(Environment.NewLine, string.Empty));
+asdfasdf
".StripNewLines(),
+ result.StripNewLines());
}
[Test]
@@ -111,8 +112,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Web.Common.Macros
Macro alias: Map
-asdfasdf
".Replace(Environment.NewLine, string.Empty),
- result.Replace(Environment.NewLine, string.Empty));
+asdfasdf
".StripNewLines(),
+ result.StripNewLines());
}
[Test]
@@ -130,8 +131,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Web.Common.Macros
Macro alias: Map
-asdfasdf
".Replace(Environment.NewLine, string.Empty),
- result.Replace(Environment.NewLine, string.Empty));
+asdfasdf
".StripNewLines(),
+ result.StripNewLines());
}
[Test]
@@ -161,8 +162,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Web.Common.Macros
Macro alias: Map
-asdfasdf
".Replace(Environment.NewLine, string.Empty),
- result.Replace(Environment.NewLine, string.Empty));
+asdfasdf
".StripNewLines(),
+ result.StripNewLines());
}
[Test]
@@ -186,8 +187,8 @@ namespace Umbraco.Cms.Tests.UnitTests.Umbraco.Web.Common.Macros
Macro alias: login
-
".Replace(Environment.NewLine, string.Empty),
- result.Replace(Environment.NewLine, string.Empty));
+
".StripNewLines(),
+ result.StripNewLines());
}
[Test]
@@ -223,8 +224,8 @@ dfdsfds"" />
asdfsdf