mu-move: add new move sub command
Add sub-command to move messages; add tests and docs. Fixes #157
This commit is contained in:
@ -71,13 +71,7 @@ make_test_store(const std::string& test_path, const TestMap& test_map,
|
||||
assert_valid_result(store);
|
||||
|
||||
/* index the messages */
|
||||
auto res = store->indexer().start({});
|
||||
g_assert_true(res);
|
||||
while(store->indexer().is_running()) {
|
||||
using namespace std::chrono_literals;
|
||||
std::this_thread::sleep_for(100ms);
|
||||
}
|
||||
|
||||
g_assert_true(store->indexer().start({},true/*block*/));
|
||||
if (test_map.size() > 0)
|
||||
g_assert_false(store->empty());
|
||||
|
||||
@ -575,7 +569,7 @@ Boo!
|
||||
assert_valid_result(moved_msgs);
|
||||
|
||||
g_assert_true(moved_msgs->size() == 1);
|
||||
auto&& moved_msg_opt = store.find_message(moved_msgs->at(0));
|
||||
auto&& moved_msg_opt = store.find_message(moved_msgs->at(0).first);
|
||||
g_assert_true(!!moved_msg_opt);
|
||||
const auto&moved_msg = std::move(*moved_msg_opt);
|
||||
const auto new_path = moved_msg.path();
|
||||
|
||||
Reference in New Issue
Block a user