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

loongson dotnet sdk 3.1.107 不能运行单元测试? dotnet test 错误 #8

Open
microestc opened this issue Jun 28, 2021 · 7 comments

Comments

@microestc
Copy link

[root@localhost dotnetprovider]# dotnet test
Test run for /root/mect/dotnetprovider/test/UnitTest/bin/Debug/netcoreapp3.1/UnitTest.dll(.NETCoreApp,Version=v3.1)
Microsoft (R) Test Execution Command Line Tool Version 16.3.0-dev+55e7e45431c9c05656c999b902686e7402664573
Copyright (c) Microsoft Corporation.  All rights reserved.

Starting test execution, please wait...

A total of 1 test files matched the specified pattern.

System.TypeInitializationException: The type initializer for 'Microsoft.VisualStudio.TestPlatform.ObjectModel.Constants' threw an exception.
 ---> System.NotSupportedException: Specified method is not supported.
   at Microsoft.VisualStudio.TestPlatform.PlatformAbstractions.PlatformEnvironment.get_Architecture()
   at Microsoft.VisualStudio.TestPlatform.ObjectModel.Utilities.XmlRunSettingsUtilities.get_OSArchitecture()
   at Microsoft.VisualStudio.TestPlatform.ObjectModel.Constants..cctor()
   --- End of inner exception stack trace ---
   at Microsoft.VisualStudio.TestPlatform.ObjectModel.RunConfiguration..ctor()
   at Microsoft.VisualStudio.TestPlatform.ObjectModel.RunConfiguration.FromXml(XmlReader reader)
   at Microsoft.VisualStudio.TestPlatform.ObjectModel.Utilities.XmlRunSettingsUtilities.GetNodeValue[T](String settingsXml, String nodeName, Func`2 nodeParser)
   at Microsoft.VisualStudio.TestPlatform.ObjectModel.Utilities.XmlRunSettingsUtilities.GetRunConfigurationNode(String settingsXml)
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.BaseRunTests.SetContext()
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.BaseRunTests..ctor(IRequestData requestData, String package, String runSettings, TestExecutionContext testExecutionContext, ITestCaseEventsHandler testCaseEventsHandler, ITestRunEventsHandler testRunEventsHandler, ITestPlatformEventSource testPlatformEventSource, ITestEventsPublisher testEventsPublisher, IThread platformThread, IDataSerializer dataSerializer)
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.BaseRunTests..ctor(IRequestData requestData, String package, String runSettings, TestExecutionContext testExecutionContext, ITestCaseEventsHandler testCaseEventsHandler, ITestRunEventsHandler testRunEventsHandler, ITestPlatformEventSource testPlatformEventSource)
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.RunTestsWithSources..ctor(IRequestData requestData, Dictionary`2 adapterSourceMap, String package, String runSettings, TestExecutionContext testExecutionContext, ITestCaseEventsHandler testCaseEventsHandler, ITestRunEventsHandler testRunEventsHandler, Dictionary`2 executorUriVsSourceList)
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.RunTestsWithSources..ctor(IRequestData requestData, Dictionary`2 adapterSourceMap, String package, String runSettings, TestExecutionContext testExecutionContext, ITestCaseEventsHandler testCaseEventsHandler, ITestRunEventsHandler testRunEventsHandler)
   at Microsoft.VisualStudio.TestPlatform.CrossPlatEngine.Execution.ExecutionManager.StartTestRun(Dictionary`2 adapterSourceMap, String package, String runSettings, TestExecutionContext testExecutionContext, ITestCaseEventsHandler testCaseEventsHandler, ITestRunEventsHandler runEventsHandler)

Test Run Aborted.

当前项目在 x86 平台没有问题, windows 和 linux 正常 从错误日志看是在启动就出错了

@microestc
Copy link
Author

`[root@localhost dotnetprovider]# cat /etc/os-release
NAME="NeoKylin Linux Server"
VERSION="7.0 (loongson)"
ID="neokylin"
ID_LIKE="fedora"
VERSION_ID="7.0"
PRETTY_NAME="NeoKylin Linux Server 7.0 (loongson)"
ANSI_COLOR="0;31"
CPE_NAME="cpe:/o:neokylin:enterprise_linux:7.0:GA:server"
HOME_URL="https://www.cs2c.com.cn/"
BUG_REPORT_URL="https://bugzilla.cs2c.com.cn/"

NEOKYLIN_BUGZILLA_PRODUCT="NeoKylin Linux Server 7.0"
NEOKYLIN_BUGZILLA_PRODUCT_VERSION=7.0
NEOKYLIN_SUPPORT_PRODUCT="NeoKylin Linux Server"
NEOKYLIN_SUPPORT_PRODUCT_VERSION="7.0"
[root@localhost dotnetprovider]#`

@microestc
Copy link
Author

`[root@localhost dotnetprovider]# dotnet --info
.NET Core SDK (reflecting any global.json):
Version: 3.1.107
Commit: 617a3e03f4

Runtime Environment:
OS Name: neokylin
OS Version: 7.0
OS Platform: Linux
RID: linux-mips64
Base Path: /root/dotnet/sdk/3.1.107/

Host (useful for support):
Version: 3.1.7
Commit: 59181f06b4

.NET Core SDKs installed:
3.1.107 [/root/dotnet/sdk]

.NET Core runtimes installed:
Microsoft.AspNetCore.App 3.1.7 [/root/dotnet/shared/Microsoft.AspNetCore.App]
Microsoft.NETCore.App 3.1.7 [/root/dotnet/shared/Microsoft.NETCore.App]

To install additional .NET Core runtimes or SDKs:
https://aka.ms/dotnet-download`

@shushanhf
Copy link
Member

Thanks~

sorry, the xunit-test is not supported on loongson-platform.

@microestc
Copy link
Author

MSTest is not supported?

@microestc
Copy link
Author

what is supported on loongson-platform.

@shushanhf
Copy link
Member

We will fix it later.

@microestc
Copy link
Author

wish loongson pay attention to support there will be no market.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants