Skip to content
This repository has been archived by the owner on Sep 3, 2022. It is now read-only.

Resolve #871 -- Upgrade to .NET Core #906

Merged
merged 39 commits into from
Oct 27, 2019
Merged

Resolve #871 -- Upgrade to .NET Core #906

merged 39 commits into from
Oct 27, 2019

Conversation

danil179
Copy link
Contributor

@danil179 danil179 commented Oct 18, 2019

This PR continues #870 PR
Fixing travis build
Then upgrading to .NET Core

Resolve #869
Resolve #871

IMPORTANT:
To reserve credit to pipe01 after squash/merge I think you have to add Co-authored-by

Copy link
Contributor Author

@danil179 danil179 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested.

Apply to #870 as well.

GameServerConsole/GameServerConsole.csproj Show resolved Hide resolved
GameServerConsoleTests/packages.config Outdated Show resolved Hide resolved
GameServerCore/GameServerCore.csproj Show resolved Hide resolved
GameServerLibTests/GameServerLibTests.csproj Outdated Show resolved Hide resolved
appveyor.yml Show resolved Hide resolved
Fixing after build events
Fixing build parameters initialization
Removing unnecessary nugets
@danil179 danil179 changed the title [WIP] PR #870 Test Merge PR #870 Test Merge Oct 18, 2019
@danil179
Copy link
Contributor Author

danil179 commented Oct 18, 2019

Again, tests with relative directories (..\..\..\..\Content for item tests) fail. I think this is because OpenCover is taken as the current directory.

@danil179 danil179 mentioned this pull request Oct 18, 2019
@danil179 danil179 changed the title PR #870 Test Merge [WIP] PR #870 Test Merge Oct 19, 2019
@danil179
Copy link
Contributor Author

Project now runs without any special problems. I'll now try to change to .NET core.

@danil179
Copy link
Contributor Author

Runtime error:

System.BadImageFormatException: 'An attempt was made to load a program with an incorrect format. (0x8007000B)'

@danil179
Copy link
Contributor Author

danil179 commented Oct 20, 2019

Everything works except log4net logger. This logger seems to ignore every settings for printing, but yet recognize it. When I run it on debug mode I see some logging and then log seems to stop.

Maybe hinders performance
@danil179 danil179 changed the title [WIP] PR #870 Test Merge PR #870 Test Merge Oct 20, 2019
@danil179
Copy link
Contributor Author

danil179 commented Oct 20, 2019

@MythicManiac It should be safe to squash&merge now, be aware that we need to add Co-authored-by that includes pipe01 as also an author of this commit.

EDIT: some tests are now broken cause path changed again

@danil179
Copy link
Contributor Author

The tests of ServerConsole get skipped as something in x86 causes problems.

@danil179
Copy link
Contributor Author

@MythicManiac I think it is safe to merge now

@danil179 danil179 changed the title PR #870 Test Merge Resolve #871 -- Upgrade to .NET Core Oct 20, 2019
Copy link
Member

@HarmfulBreeze HarmfulBreeze left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Didn't see anything out of place really, if it works, it probably should be merged.

GameServerConsole/GameServerConsole.csproj Show resolved Hide resolved
@@ -25,7 +24,7 @@ public class BaseTurret : ObjAiBase, IBaseTurret
uint netId = 0
) : base(game, model, new Stats.Stats(), 50, x, y, 1200, netId)
{
ParentNetId = Crc32Algorithm.Compute(Encoding.UTF8.GetBytes(name)) | 0xFF000000;
ParentNetId = Force.Crc32.Crc32Algorithm.Compute(Encoding.UTF8.GetBytes(name)) | 0xFF000000;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not sure why this was inlined

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

VS marked the using line as problematic for no reason so I just copied it here. I don't mind changing it back if VS do no problems with that.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah we'd rather have one more using directive than a line that's harder to read

[DeploymentItem("Content", "Content")]
public void TestItemContentCollection()
{
var collection = ItemContentCollection.LoadItemsFrom("Content/Data/LeagueSandbox-Default/Items");
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file probably got deleted by mistake. I'll upload it back.

.travis.yml Show resolved Hide resolved
Added removed files that were removed by mistake
@danil179
Copy link
Contributor Author

Travis can't run tests without stalling: microsoft/vstest#2080

Copy link
Member

@HarmfulBreeze HarmfulBreeze left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@moonshadow565
Copy link
Member

What about instead of <TargetFramework>netcoreapp3.0</TargetFramework> target <TargetFramework>netstandard2.1</TargetFramework> instead ?

@danil179 danil179 merged commit 93f9165 into LeagueSandbox:indev Oct 27, 2019
@danil179 danil179 deleted the pipe01-patch-1 branch October 27, 2019 07:50
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Use .NET Core Migrate projects to new csproj format
5 participants