2024-07-18 06:32:27 +03:00
|
|
|
// FIXME: Odd failures for templates that are causing the PR to break
|
|
|
|
// for now with discussion with @Ericson2314 to comment out.
|
|
|
|
#if 0
|
|
|
|
# include <gtest/gtest.h>
|
2024-07-15 20:13:11 +03:00
|
|
|
|
2024-07-18 06:32:27 +03:00
|
|
|
# include "ssh-store.hh"
|
2024-07-15 20:13:11 +03:00
|
|
|
|
|
|
|
namespace nix {
|
|
|
|
|
|
|
|
TEST(SSHStore, constructConfig)
|
|
|
|
{
|
|
|
|
SSHStoreConfig config{
|
|
|
|
"ssh",
|
|
|
|
"localhost",
|
|
|
|
StoreConfig::Params{
|
|
|
|
{
|
|
|
|
"remote-program",
|
|
|
|
// TODO #11106, no more split on space
|
|
|
|
"foo bar",
|
|
|
|
},
|
2024-07-18 06:32:27 +03:00
|
|
|
},
|
|
|
|
};
|
|
|
|
|
2024-07-15 20:13:11 +03:00
|
|
|
EXPECT_EQ(
|
|
|
|
config.remoteProgram.get(),
|
|
|
|
(Strings{
|
|
|
|
"foo",
|
|
|
|
"bar",
|
|
|
|
}));
|
|
|
|
}
|
2024-07-18 06:32:27 +03:00
|
|
|
|
|
|
|
TEST(MountedSSHStore, constructConfig)
|
|
|
|
{
|
|
|
|
MountedSSHStoreConfig config{
|
|
|
|
"mounted-ssh",
|
|
|
|
"localhost",
|
|
|
|
StoreConfig::Params{
|
|
|
|
{
|
|
|
|
"remote-program",
|
|
|
|
// TODO #11106, no more split on space
|
|
|
|
"foo bar",
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
|
|
|
|
|
|
|
EXPECT_EQ(
|
|
|
|
config.remoteProgram.get(),
|
|
|
|
(Strings{
|
|
|
|
"foo",
|
|
|
|
"bar",
|
|
|
|
}));
|
|
|
|
}
|
|
|
|
|
2024-07-15 20:13:11 +03:00
|
|
|
}
|
2024-07-18 06:32:27 +03:00
|
|
|
#endif
|