Skip to content

Commit

Permalink
Merge pull request #39872 from jbytheway/tests_custom_user_dir
Browse files Browse the repository at this point in the history
Tests should use different default user dir
  • Loading branch information
ralreegorganon authored Apr 25, 2020
2 parents 9f6568b + 15e0954 commit d834d7a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ Cataclysm.dmg
/tests/map_iterator_test
/tests/shadowcasting_test
/tests/data/jsionized_overmap.sav
/test_user_dir

# temporary files generated by tools/reduce_tests.sh
/list_of_tests
Expand Down
2 changes: 1 addition & 1 deletion tests/test_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ static std::string extract_user_dir( std::vector<const char *> &arg_vec )
{
std::string option_user_dir = extract_argument( arg_vec, "--user-dir=" );
if( option_user_dir.empty() ) {
return "./";
return "./test_user_dir/";
}
if( !string_ends_with( option_user_dir, "/" ) ) {
option_user_dir += "/";
Expand Down

0 comments on commit d834d7a

Please sign in to comment.