Formatting and disable warningsaserrors on tests
This commit is contained in:
@@ -84,16 +84,19 @@ public abstract class ConvertBlockEditorPropertiesBase : MigrationBase
|
||||
continue;
|
||||
}
|
||||
|
||||
_logger.LogInformation("Migration starting for all properties of type: {propertyEditorAlias}",
|
||||
_logger.LogInformation(
|
||||
"Migration starting for all properties of type: {propertyEditorAlias}",
|
||||
propertyEditorAlias);
|
||||
if (Handle(propertyTypes, languagesById))
|
||||
{
|
||||
_logger.LogInformation("Migration succeeded for all properties of type: {propertyEditorAlias}",
|
||||
_logger.LogInformation(
|
||||
"Migration succeeded for all properties of type: {propertyEditorAlias}",
|
||||
propertyEditorAlias);
|
||||
}
|
||||
else
|
||||
{
|
||||
_logger.LogError("Migration failed for one or more properties of type: {propertyEditorAlias}",
|
||||
_logger.LogError(
|
||||
"Migration failed for one or more properties of type: {propertyEditorAlias}",
|
||||
propertyEditorAlias);
|
||||
}
|
||||
}
|
||||
@@ -154,7 +157,8 @@ public abstract class ConvertBlockEditorPropertiesBase : MigrationBase
|
||||
Task task;
|
||||
using (ExecutionContext.SuppressFlow())
|
||||
{
|
||||
task = Task.Run(() =>
|
||||
task = Task.Run(
|
||||
() =>
|
||||
{
|
||||
using ICoreScope scope = _coreScopeProvider.CreateCoreScope();
|
||||
scope.Complete();
|
||||
@@ -173,7 +177,8 @@ public abstract class ConvertBlockEditorPropertiesBase : MigrationBase
|
||||
// NOTE: some old property data DTOs can have variance defined, even if the property type no longer varies
|
||||
var culture = propertyType.VariesByCulture()
|
||||
&& propertyDataDto.LanguageId.HasValue
|
||||
&& languagesById.TryGetValue(propertyDataDto.LanguageId.Value,
|
||||
&& languagesById.TryGetValue(
|
||||
propertyDataDto.LanguageId.Value,
|
||||
out ILanguage? language)
|
||||
? language.IsoCode
|
||||
: null;
|
||||
|
||||
@@ -136,9 +136,7 @@ internal abstract class BlockValuePropertyIndexValueFactoryBase<TSerialized> : J
|
||||
indexData.Add(
|
||||
ToRawData(
|
||||
blockItemData.ContentTypeKey,
|
||||
blockItemData.Values.Where(value => value.Culture is null || exposedCultures.Contains(value.Culture))
|
||||
)
|
||||
);
|
||||
blockItemData.Values.Where(value => value.Culture is null || exposedCultures.Contains(value.Culture))));
|
||||
}
|
||||
|
||||
return indexData;
|
||||
|
||||
@@ -8,8 +8,9 @@
|
||||
<IsPackable>false</IsPackable>
|
||||
<BaseEnablePackageValidation>$(EnablePackageValidation)</BaseEnablePackageValidation>
|
||||
<EnablePackageValidation>false</EnablePackageValidation>
|
||||
<TreatWarningsAsErrors>false</TreatWarningsAsErrors>
|
||||
</PropertyGroup>
|
||||
|
||||
|
||||
<PropertyGroup>
|
||||
<!-- TODO: Update test projects to use nullable reference types and remove this to enable nullable warnings as errors (the solution default) -->
|
||||
<Nullable>annotations</Nullable>
|
||||
|
||||
Reference in New Issue
Block a user