public void ConvertLocalPathToUnc() { var path = "E:\\bob\\bill"; var expected = @"\\{0}\E$\bob\bill".FormatWith(Environment.MachineName); var actual = RemotePathHelper.Convert(Environment.MachineName, path); Assert.AreEqual(expected, actual); }
public void ConvertRemotePathToUnc() { var server = "SrvTopeka01"; var path = "E:\\bob\\bill"; var expected = @"\\SrvTopeka01\E$\bob\bill"; var actual = RemotePathHelper.Convert(server, path); Assert.AreEqual(expected, actual); }
public void WhatShouldWeDoIfYouProvideUncAndTheServerIsDifferent() { var server = "SrvTopeka01"; var path = "bob\\bill"; var expected = @"\\SrvTopeka01\bob\bill"; var actual = RemotePathHelper.Convert(server, path); Assert.AreEqual(expected, actual); }
public void ShouldBeAbleToUseTilda() { var server = "SrvTopeka01"; var path = "~\\bob\\bill"; var expected = @"\\SrvTopeka01\bob\bill"; var actual = RemotePathHelper.Convert(server, path); Assert.AreEqual(expected, actual); }