temp = File.createTempFile("foo", "bar");
try {
SshClient client = setupClient();
client.put(temp.getAbsolutePath(), Payloads.newStringPayload("rabbit"));
Payload input = setupClient().get(temp.getAbsolutePath());
String contents = Strings2.toStringAndClose(input.openStream());
assertEquals(contents, "rabbit");
} finally {
temp.delete();
}
}