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

OSOE-795: Upgrade to latest OC preview to test System.Text.Json #712

Merged
merged 151 commits into from
May 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
151 commits
Select commit Hold shift + click to select a range
a186920
Add clear to the NuGet.config.
sarahelsaig Feb 22, 2024
1cab55b
Update local NuGet versions and pull unchanged submodules
sarahelsaig Feb 22, 2024
92639f2
update submodules
sarahelsaig Feb 22, 2024
50af1e0
submodules
sarahelsaig Feb 22, 2024
7a21224
Prevent package downgrade.
sarahelsaig Feb 22, 2024
1c96880
Fix compilation errors.
sarahelsaig Feb 23, 2024
7886ff5
submodules
sarahelsaig Feb 24, 2024
1242f55
Remove remaining Newtonsoft referenes.
sarahelsaig Feb 24, 2024
5a4b335
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig Feb 25, 2024
e4e75d0
Clarify SuppressMessage Justification.
sarahelsaig Feb 25, 2024
696a414
Fix new warnings.
sarahelsaig Feb 25, 2024
d256d79
Fix broken DateTime conversion during tests and broken mixed type num…
sarahelsaig Feb 25, 2024
1bb8d9e
Fix warnings
sarahelsaig Feb 25, 2024
f6dc0b5
unusing
sarahelsaig Feb 25, 2024
341ba8b
Temporarily increase timeout.
sarahelsaig Feb 25, 2024
ad74f82
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig Feb 26, 2024
6177183
Fix uninitialized IActionContextAccessor in UsingScopeAsync and Execu…
sarahelsaig Feb 26, 2024
5172b99
Fix uninitialized IActionContextAccessor in UsingScopeAsync and Execu…
sarahelsaig Feb 26, 2024
a1366b6
Merge branch 'issue/OSOE-795-backport' into issue/OSOE-795
sarahelsaig Feb 26, 2024
84b9d86
View bug fix.
sarahelsaig Feb 26, 2024
daa5768
Lombiq.DataTables
sarahelsaig Feb 26, 2024
11c129c
Add missing using.
sarahelsaig Feb 26, 2024
6ed2622
Fix Features atata map.
sarahelsaig Feb 27, 2024
b8f9258
update submodules
sarahelsaig Mar 1, 2024
7c5a2f2
Merge remote-tracking branch 'origin/dev' into issue/OSOE-795
sarahelsaig Mar 1, 2024
0116d4c
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig Mar 3, 2024
39fc98d
Fix JS syntax error.
sarahelsaig Mar 3, 2024
90299e9
Fix test.
sarahelsaig Mar 3, 2024
9e1e950
Update OC to latest (because of bug fix for WorkflowTypeStep)
sarahelsaig Mar 3, 2024
bc6794e
Update OC to latest (because of bug fix for WorkflowTypeStep)
sarahelsaig Mar 3, 2024
8df3d92
ISmtpService is obsolete.
sarahelsaig Mar 3, 2024
1ea0cc6
SmtpResult is obsolete.
sarahelsaig Mar 3, 2024
ab333e8
Fix OrchardCoreApiClientShouldWork
sarahelsaig Mar 4, 2024
a666e2c
unusing
sarahelsaig Mar 4, 2024
e89949d
Not needed after all.
sarahelsaig Mar 4, 2024
68b0af5
unusing
sarahelsaig Mar 4, 2024
ff3bcf8
Skip BehaviorFeaturesGuardTests for now.
sarahelsaig Mar 4, 2024
a192d35
Fix ReplaceDefaultShapeTableManager which was crashing due to keyed s…
sarahelsaig Mar 4, 2024
b183b5b
Fix typo.
sarahelsaig Mar 4, 2024
5992e68
use ExecuteJsonRecipeSiteSettingAsync
sarahelsaig Mar 4, 2024
0110011
ExecuteJsonRecipeSiteSettingAsync
sarahelsaig Mar 4, 2024
e8fdd3d
Update OC preview version.
sarahelsaig Mar 7, 2024
c17f09b
Fix package downgrade.
sarahelsaig Mar 7, 2024
7ba13a5
Update visual verification.
sarahelsaig Mar 8, 2024
0a2c180
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig Mar 10, 2024
770e86c
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig Mar 12, 2024
adfa857
Update code generation test due to change in serialization.
sarahelsaig Mar 13, 2024
e79ad46
submodule
sarahelsaig Mar 13, 2024
21c0e90
Update OC package
sarahelsaig Mar 13, 2024
7b093d4
Use new email test extension methods from UITT.
sarahelsaig Mar 13, 2024
c7a6706
Update SmtpSettings recipe.
sarahelsaig Mar 13, 2024
7c94764
Add favicon.ico as a fallback to avoid having to handle its 404 error…
sarahelsaig Mar 13, 2024
3912a75
Add JOptions spelling.
sarahelsaig Mar 13, 2024
fcb23bc
submodules
sarahelsaig Mar 15, 2024
6565def
unusing
sarahelsaig Mar 15, 2024
4ec6e46
Default Host and IsEnabled.
sarahelsaig Mar 15, 2024
7f56b5f
update submodules
sarahelsaig Mar 16, 2024
7df872a
Merge remote-tracking branch 'origin/dev' into issue/OSOE-795
sarahelsaig Mar 16, 2024
40b387f
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig Mar 16, 2024
f81c21a
Revert mysterious unintended change.
sarahelsaig Mar 16, 2024
f2cd365
Revert tenants
sarahelsaig Mar 16, 2024
1fa8b90
Also show warning on the email testing page.
sarahelsaig Mar 16, 2024
1da5090
Fix SuccessResult usage.
sarahelsaig Mar 17, 2024
dc6120b
Configure port settings also.
sarahelsaig Mar 17, 2024
b856986
Temporary hack to verify the solution for https://github.com/OrchardC…
sarahelsaig Mar 17, 2024
67817b9
bug fix
sarahelsaig Mar 17, 2024
c7c7abc
Fix warning SA1311.
sarahelsaig Mar 18, 2024
ce797a3
Replace AdminRouteAttribute with AdminAttribute.
sarahelsaig Mar 18, 2024
99798f2
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig Mar 21, 2024
5e9ff1a
Merge remote-tracking branch 'origin/dev' into issue/OSOE-795
sarahelsaig Mar 23, 2024
e3a05f8
Update submodules
sarahelsaig Mar 29, 2024
702311f
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig Mar 29, 2024
bc711b5
Update submodules
sarahelsaig Mar 29, 2024
5109e5f
Update NodaTime.
sarahelsaig Mar 29, 2024
23caff9
Temporarily block SqlServerTests.
sarahelsaig Apr 2, 2024
ad25195
Use JObject.FromObject instead of JsonSerializer.SerializeToNode wher…
sarahelsaig Apr 2, 2024
b903113
Rename verification test to match expectation.
sarahelsaig Apr 2, 2024
f982028
Always generate the verification image in GitHub environment.
sarahelsaig Apr 2, 2024
00e93f9
submodules
sarahelsaig Apr 22, 2024
a8071b8
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig Apr 22, 2024
f4a613c
Remove leftover Newtonseft JsonConvert.
sarahelsaig Apr 22, 2024
5f31f89
Show error messages in page change assertion failure.
sarahelsaig Apr 23, 2024
e247678
SerializeAndDeserialize
sarahelsaig Apr 23, 2024
0e15085
Add JNode to spelling
sarahelsaig Apr 23, 2024
7672b4a
unusing
sarahelsaig Apr 23, 2024
0744397
Update OC preview version.
sarahelsaig Apr 23, 2024
cce661a
post update fixup
sarahelsaig Apr 23, 2024
b1ddcb7
Update AddCondition to AddRuleCondition
sarahelsaig Apr 23, 2024
1aec07c
Update UpdateAsync.
sarahelsaig Apr 23, 2024
d53d5ec
fix build errors
sarahelsaig Apr 23, 2024
abb5c24
unusing
sarahelsaig Apr 23, 2024
9d567e7
Update login atata thing.
sarahelsaig Apr 23, 2024
43a4d31
Update login form IDs for walkthroughs.js.
sarahelsaig Apr 23, 2024
c47d788
Use the new DisplayDriver<RegisterUserForm> to inject registration ch…
sarahelsaig Apr 25, 2024
f3ddf74
Add missing location.
sarahelsaig Apr 25, 2024
ac7eb3e
Remove duplicate filter.
sarahelsaig Apr 25, 2024
0050cee
unusing
sarahelsaig Apr 25, 2024
0e29cc8
Update registration form IDs.
sarahelsaig Apr 25, 2024
6d6fdeb
Update OrchardCoreRegistrationPage.
sarahelsaig Apr 25, 2024
60427d2
no
sarahelsaig Apr 25, 2024
0749841
Fix S1854.
sarahelsaig Apr 25, 2024
a695ad1
LoginForm_
sarahelsaig Apr 25, 2024
930777b
Update OC package version.
sarahelsaig Apr 27, 2024
9155833
Update OC package version.
sarahelsaig Apr 27, 2024
dec2d4e
submodules
sarahelsaig May 4, 2024
c5e06d5
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig May 4, 2024
e7b9524
Update OC versions
sarahelsaig May 4, 2024
9eb333c
Update OC versions
sarahelsaig May 4, 2024
eccff77
Unskip tests.
sarahelsaig May 4, 2024
6773d4a
Post merge and OC update fixup
sarahelsaig May 4, 2024
e532fb2
Post merge and OC update fixup
sarahelsaig May 4, 2024
fe4eb69
unusing
sarahelsaig May 4, 2024
28ec51e
unusing
sarahelsaig May 4, 2024
83cb515
Update submodule
sarahelsaig May 7, 2024
089080b
Update OC to the latest preview.
sarahelsaig May 7, 2024
de02465
Merge remote-tracking branch 'origin/dev' into issue/OSOE-795
sarahelsaig May 7, 2024
e704023
Make sure the middlewares run first for real.
sarahelsaig May 7, 2024
40e3cf9
Only override ConfigureOrder, not Order.
sarahelsaig May 7, 2024
1493fd3
To ensure we don't encounter any concurrency issue, enable EnableThre…
sarahelsaig May 7, 2024
4d3a3ce
submodules
sarahelsaig May 7, 2024
b1b950e
Fix training demo code for standalone build.
sarahelsaig May 7, 2024
41422d7
Code cleanup.
sarahelsaig May 7, 2024
9c17bd8
Replace strange leftover `var` with `const`.
sarahelsaig May 10, 2024
9110747
Revert timeout.
sarahelsaig May 10, 2024
0206626
submodule
sarahelsaig May 10, 2024
1e2047e
spell-check-ignore-line again
sarahelsaig May 10, 2024
c540eba
submodule
sarahelsaig May 12, 2024
204b63d
Add DataLabelAlignmentConfigurationShouldSerializeCorrectly test
sarahelsaig May 12, 2024
986dcf9
Use JsonPropertyName for camelCase.
sarahelsaig May 12, 2024
325b0b6
Update test.
sarahelsaig May 12, 2024
c0cbde7
submodule
sarahelsaig May 12, 2024
a442492
submodule
sarahelsaig May 12, 2024
5f4e49b
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig May 12, 2024
2809205
submodules.
sarahelsaig May 12, 2024
0a9ec84
Get rid of `[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonK…
sarahelsaig May 12, 2024
fd13162
Get rid of `[JsonSourceGenerationOptions(PropertyNamingPolicy = JsonK…
sarahelsaig May 12, 2024
6f616fc
merge
sarahelsaig May 12, 2024
e4d5f4b
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig May 12, 2024
398f813
Post merge fixup.
sarahelsaig May 13, 2024
3096d0b
Update test.
sarahelsaig May 13, 2024
e354c66
Update test again.
sarahelsaig May 13, 2024
5123f08
Reverting branch reference to dev
dministro May 15, 2024
3baeb6c
Updating submodules
dministro May 15, 2024
83a64bf
submodules
sarahelsaig May 16, 2024
85a96bc
submodules
sarahelsaig May 16, 2024
4d3307b
Merge branch 'task/system-text-json-migration' into issue/OSOE-795
sarahelsaig May 16, 2024
8e678e0
Merge branch 'issue/OSOE-795' of https://github.com/Lombiq/Open-Sourc…
sarahelsaig May 16, 2024
b4b7a73
Fix consolidation.
sarahelsaig May 16, 2024
365008d
Hack not needed any more.
sarahelsaig May 16, 2024
cd79649
unusing
sarahelsaig May 16, 2024
90cc932
Updating submodule
dministro May 16, 2024
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
1 change: 1 addition & 0 deletions NuGet.config
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
<configuration>
<packageSources>
<!-- Here, so the Visual Studio package manager won't default to the next feed below. -->
<clear />
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
<add key="OrchardCorePreview" value="https://nuget.cloudsmith.io/orchardcore/preview/v3/index.json" />
</packageSources>
Expand Down
8 changes: 4 additions & 4 deletions src/Lombiq.OSOCE.Web/Lombiq.OSOCE.Web.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="OrchardCore.Admin.Abstractions" Version="1.8.2" />
<PackageReference Include="OrchardCore.Application.Cms.Targets" Version="1.8.2" />
<PackageReference Include="OrchardCore.Logging.NLog" Version="1.8.2" />
<PackageReference Include="SixLabors.ImageSharp.Web" Version="3.1.0" />
<PackageReference Include="OrchardCore.Admin.Abstractions" Version="2.0.0-preview-18200" />
<PackageReference Include="OrchardCore.Application.Cms.Targets" Version="2.0.0-preview-18200" />
<PackageReference Include="OrchardCore.Logging.NLog" Version="2.0.0-preview-18200" />
<PackageReference Include="SixLabors.ImageSharp.Web" Version="3.1.2" />
</ItemGroup>

</Project>
7 changes: 6 additions & 1 deletion src/Lombiq.OSOCE.Web/Recipes/Lombiq.OSOCE.Tests.recipe.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
"Lombiq.Hosting.Tenants.MediaStorageManagement",
"OrchardCore.Media",
"OrchardCore.Feature",
"OrchardCore.Email.Smtp",
"TheTheme"
// Not enabling Lombiq.TrainingDemo.Middlewares because that would write to the error log on every request.
]
Expand Down Expand Up @@ -91,8 +92,12 @@
"name": "settings",
// CDN should be turned off for tests, just as no other external resource should be used.
"UseCdn": false,
// A breaking change as of OC 1.9, the SMTP e-mail provider is not turned on by default and has to be enabled.
// Also host is null by default, so has to be explicitly specified.
"SmtpSettings": {
"DefaultSender": "[email protected]"
"IsEnabled": true,
"DefaultSender": "[email protected]",
"Host": "localhost"
},
// To make sure that e.g. numbers and dates are formatted the same way on all machines we have to specify the
// culture too.
Expand Down
Binary file added src/Lombiq.OSOCE.Web/wwwroot/favicon.ico
Binary file not shown.
8 changes: 4 additions & 4 deletions src/Modules/Lombiq.OSOCE.Samples/Lombiq.OSOCE.Samples.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
</ItemGroup>

<ItemGroup>
<PackageReference Include="OrchardCore.Module.Targets" Version="1.8.2" />
<PackageReference Include="OrchardCore.ContentManagement" Version="1.8.2" />
<PackageReference Include="OrchardCore.ContentTypes.Abstractions" Version="1.8.2" />
<PackageReference Include="OrchardCore.DisplayManagement" Version="1.8.2" />
<PackageReference Include="OrchardCore.Module.Targets" Version="2.0.0-preview-18200" />
<PackageReference Include="OrchardCore.ContentManagement" Version="2.0.0-preview-18200" />
<PackageReference Include="OrchardCore.ContentTypes.Abstractions" Version="2.0.0-preview-18200" />
<PackageReference Include="OrchardCore.DisplayManagement" Version="2.0.0-preview-18200" />
</ItemGroup>

<ItemGroup>
Expand Down
3 changes: 2 additions & 1 deletion test/Lombiq.OSOCE.Tests.UI/Helpers/AssertAppLogsHelpers.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ public static async Task OsoceLogsShouldBeEmptyAsync(
!message.Contains("|Lombiq.TrainingDemo.Services.DemoBackgroundTask|ERROR|Expected non-error") &&
!message.Contains("OrchardCore.Media.Core.DefaultMediaFileStoreCacheFileProvider|ERROR|Error deleting cache folder"));

filteredLogOutput.ShouldNotContain(item => item.Contains("|ERROR|") || item.Contains("|FATAL|"));
var errors = filteredLogOutput.Where(item => item.Contains("|ERROR|") || item.Contains("|FATAL|"));
errors.ShouldBeEmpty();
}
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
using Lombiq.ChartJs.Models;
using Lombiq.ChartJs.Tests.UI.Extensions;
using Shouldly;
using System.Text.Json;
using System.Threading.Tasks;
using Xunit;
using Xunit.Abstractions;
Expand All @@ -15,4 +18,26 @@ public BehaviorChartJsTests(ITestOutputHelper testOutputHelper)
[Fact]
public Task RecipeDataShouldBeDisplayedCorrectly() =>
ExecuteTestAfterSetupAsync(context => context.TestChartJsSampleBehaviorAsync());

[Fact]
public void DataLabelAlignmentConfigurationShouldSerializeCorrectly()
{
var data = new DataLabelAlignmentConfiguration
{
Align = DataLabelAlignment.Start,
Anchor = DataLabelAlignment.Center,
Font = new DataLabelAlignmentConfiguration.FontStyle { IsBold = true, Size = 16.5 },
Offset = 3.14,
};

var json = JsonSerializer.Serialize(data);
json.ShouldBe("{\"align\":\"start\",\"anchor\":\"center\",\"offset\":3.14,\"font\":{\"size\":16.5,\"weight\":\"bold\"}}");

var deserialized = JsonSerializer.Deserialize<DataLabelAlignmentConfiguration>(json);
deserialized.Align.ShouldBe(data.Align);
deserialized.Anchor.ShouldBe(data.Anchor);
deserialized.Font.IsBold.ShouldBe(data.Font.IsBold);
deserialized.Font.Size.ShouldBe(data.Font.Size);
deserialized.Offset.ShouldBe(data.Offset);
}
}
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading