【发布时间】:2018-03-07 07:10:58
【问题描述】:
我在 .Net Core 2 中有一个测试用例,我在其中向Path.GetDirectoryName 提供以下输入。
@"C:" + Path.DirectorySeparatorChar
当我在我的测试用例中断言Path.GetDirectoryName时,它返回nullfor Windows OS,但返回C:for Linux OS,为什么会这样?
谁能解释一下我在这里做错了什么?
【问题讨论】:
标签: c# linux path nunit .net-core-2.0