Extended cli_handler test cases (#287)
This commit is contained in:
@@ -389,6 +389,11 @@ runtime_config cli_handler::get_runtime_config() const
|
||||
return cfg;
|
||||
}
|
||||
|
||||
void cli_handler::set_config_path(const std::string &path)
|
||||
{
|
||||
config_path = path;
|
||||
}
|
||||
|
||||
cli_flow_t cli_handler::print_version()
|
||||
{
|
||||
ostr_ << "clang-uml " << clanguml::version::CLANG_UML_VERSION << '\n';
|
||||
@@ -477,7 +482,7 @@ cli_flow_t cli_handler::create_config_file()
|
||||
{
|
||||
namespace fs = std::filesystem;
|
||||
|
||||
fs::path config_file{"./.clang-uml"};
|
||||
fs::path config_file{config_path};
|
||||
|
||||
if (fs::exists(config_file)) {
|
||||
ostr_ << "ERROR: .clang-uml file already exists\n";
|
||||
|
||||
@@ -153,6 +153,13 @@ public:
|
||||
*/
|
||||
runtime_config get_runtime_config() const;
|
||||
|
||||
/**
|
||||
* @brief Set the default config path
|
||||
*
|
||||
* @param path
|
||||
*/
|
||||
void set_config_path(const std::string &path);
|
||||
|
||||
std::string config_path{".clang-uml"};
|
||||
std::optional<std::string> compilation_database_dir{};
|
||||
std::vector<std::string> diagram_names{};
|
||||
|
||||
Reference in New Issue
Block a user