Retrieve LeafOutput operational
This commit is contained in:
@@ -16,7 +16,7 @@ namespace LeafWeb.Core.Tests.Remote
|
||||
Filename = "blah",
|
||||
LeafInputId = 1,
|
||||
Contents = "test".GetBytes(),
|
||||
DirectoryName = "TestDirectory"
|
||||
DirectoryName = "TestDirectory2"
|
||||
};
|
||||
|
||||
private readonly string _piscalConnectionString =
|
||||
@@ -33,15 +33,17 @@ namespace LeafWeb.Core.Tests.Remote
|
||||
public void GetLeafInputStatus()
|
||||
{
|
||||
var client = new PiscalSshClient(_piscalConnectionString);
|
||||
client.GetLeafInputStatus(_testInput);
|
||||
var leafInputStatus = client.GetLeafInputStatus(_testInput);
|
||||
Console.WriteLine(leafInputStatus);
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void RetrieveLeafInputResult()
|
||||
public void RetrieveLeafOutput()
|
||||
{
|
||||
var client = new PiscalSshClient(_piscalConnectionString);
|
||||
var result = client.RetrieveLeafInputResult(_testInput).ToList();
|
||||
Console.WriteLine(result[0].Contents.GetString());
|
||||
var result = client.RetrieveLeafOutput(_testInput).ToList();
|
||||
Console.WriteLine(string.Join(", ", result.Select(o => o.Filename)));
|
||||
//Console.WriteLine(result[0].Contents.GetString());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -38,5 +38,13 @@ namespace LeafWeb.Core.Tests.Utility
|
||||
var result = str.FilterAlphaNumeric();
|
||||
Assert.That(result, Is.EqualTo("newline"));
|
||||
}
|
||||
|
||||
[Test]
|
||||
public void FilenameFromPath()
|
||||
{
|
||||
var str = "/full/path/to/file.ext";
|
||||
var result = str.FilenameFromPath();
|
||||
Assert.That(result, Is.EqualTo("file.ext"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user