Avoid file name collisions in dump unit tests
This commit is contained in:
@ -39,6 +39,21 @@ public:
|
||||
END_HIDE_OUTPUT();
|
||||
}
|
||||
|
||||
std::string dump_filename(std::string ident)
|
||||
{
|
||||
return fmt::format("dump_{}_{}.melt", dump_style, ident);
|
||||
}
|
||||
|
||||
std::string text_dump_filename(std::string ident)
|
||||
{
|
||||
return fmt::format("dump_{}_text_{}.melt", dump_style, ident);
|
||||
}
|
||||
|
||||
std::string binary_dump_filename(std::string ident)
|
||||
{
|
||||
return fmt::format("dump_{}_binary_{}.melt.bin", dump_style, ident);
|
||||
}
|
||||
|
||||
void generate_dump(std::string dump_file, std::string dump_modify_options, int ntimesteps)
|
||||
{
|
||||
BEGIN_HIDE_OUTPUT();
|
||||
@ -87,7 +102,7 @@ public:
|
||||
|
||||
TEST_F(DumpAtomTest, run0)
|
||||
{
|
||||
auto dump_file = "dump_run0.melt";
|
||||
auto dump_file = dump_filename("run0");
|
||||
generate_dump(dump_file, "scale yes image no", 0);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -103,7 +118,7 @@ TEST_F(DumpAtomTest, run0)
|
||||
|
||||
TEST_F(DumpAtomTest, format_line_run0)
|
||||
{
|
||||
auto dump_file = "dump_format_line_run0.melt";
|
||||
auto dump_file = dump_filename("format_line_run0");
|
||||
generate_dump(dump_file, "format line \"%d %d %20.15g %g %g\" scale yes image no", 0);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -119,7 +134,7 @@ TEST_F(DumpAtomTest, format_line_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, no_scale_run0)
|
||||
{
|
||||
auto dump_file = "dump_no_scale_run0.melt";
|
||||
auto dump_file = dump_filename("no_scale_run0");
|
||||
generate_dump(dump_file, "scale off", 0);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -134,7 +149,7 @@ TEST_F(DumpAtomTest, no_scale_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, no_buffer_no_scale_run0)
|
||||
{
|
||||
auto dump_file = "dump_no_buffer_no_scale_run0.melt";
|
||||
auto dump_file = dump_filename("no_buffer_no_scale_run0");
|
||||
generate_dump(dump_file, "buffer false scale false", 0);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -149,7 +164,7 @@ TEST_F(DumpAtomTest, no_buffer_no_scale_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, no_buffer_with_scale_run0)
|
||||
{
|
||||
auto dump_file = "dump_no_buffer_with_scale_run0.melt";
|
||||
auto dump_file = dump_filename("no_buffer_with_scale_run0");
|
||||
generate_dump(dump_file, "buffer 0 scale 1", 0);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -164,7 +179,7 @@ TEST_F(DumpAtomTest, no_buffer_with_scale_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, with_image_run0)
|
||||
{
|
||||
auto dump_file = "dump_with_image_run0.melt";
|
||||
auto dump_file = dump_filename("with_image_run0");
|
||||
generate_dump(dump_file, "scale no image on", 0);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -177,7 +192,7 @@ TEST_F(DumpAtomTest, with_image_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, with_units_run0)
|
||||
{
|
||||
auto dump_file = "dump_with_units_run0.melt";
|
||||
auto dump_file = dump_filename("with_units_run0");
|
||||
generate_dump(dump_file, "scale false units 1", 0);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -192,7 +207,7 @@ TEST_F(DumpAtomTest, with_units_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, with_time_run0)
|
||||
{
|
||||
auto dump_file = "dump_with_time_run0.melt";
|
||||
auto dump_file = dump_filename("with_time_run0");
|
||||
generate_dump(dump_file, "scale off time true", 0);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -206,7 +221,7 @@ TEST_F(DumpAtomTest, with_time_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, with_units_run1)
|
||||
{
|
||||
auto dump_file = "dump_with_units_run1.melt";
|
||||
auto dump_file = dump_filename("with_units_run1");
|
||||
generate_dump(dump_file, "scale 0 units on", 1);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -221,7 +236,7 @@ TEST_F(DumpAtomTest, with_units_run1)
|
||||
|
||||
TEST_F(DumpAtomTest, no_buffer_with_scale_and_image_run0)
|
||||
{
|
||||
auto dump_file = "dump_no_buffer_with_scale_and_image_run0.melt";
|
||||
auto dump_file = dump_filename("no_buffer_with_scale_and_image_run0");
|
||||
generate_dump(dump_file, "buffer 0 scale 1 image true", 0);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -235,7 +250,7 @@ TEST_F(DumpAtomTest, no_buffer_with_scale_and_image_run0)
|
||||
}
|
||||
TEST_F(DumpAtomTest, triclinic_run0)
|
||||
{
|
||||
auto dump_file = "dump_triclinic_run0.melt";
|
||||
auto dump_file = dump_filename("triclinic_run0");
|
||||
enable_triclinic();
|
||||
generate_dump(dump_file, "", 0);
|
||||
|
||||
@ -251,7 +266,7 @@ TEST_F(DumpAtomTest, triclinic_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, triclinic_with_units_run0)
|
||||
{
|
||||
auto dump_file = "dump_triclinic_with_units_run0.melt";
|
||||
auto dump_file = dump_filename("triclinic_with_units_run0");
|
||||
enable_triclinic();
|
||||
generate_dump(dump_file, "units on", 0);
|
||||
|
||||
@ -269,7 +284,7 @@ TEST_F(DumpAtomTest, triclinic_with_units_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, triclinic_with_time_run0)
|
||||
{
|
||||
auto dump_file = "dump_triclinic_with_time_run0.melt";
|
||||
auto dump_file = dump_filename("triclinic_with_time_run0");
|
||||
enable_triclinic();
|
||||
generate_dump(dump_file, "time on", 0);
|
||||
|
||||
@ -286,7 +301,7 @@ TEST_F(DumpAtomTest, triclinic_with_time_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, triclinic_with_image_run0)
|
||||
{
|
||||
auto dump_file = "dump_triclinic_with_image_run0.melt";
|
||||
auto dump_file = dump_filename("triclinic_with_image_run0");
|
||||
enable_triclinic();
|
||||
generate_dump(dump_file, "image yes", 0);
|
||||
|
||||
@ -308,8 +323,8 @@ TEST_F(DumpAtomTest, binary_run0)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto text_file = "dump_text_run0.melt";
|
||||
auto binary_file = "dump_binary_run0.melt.bin";
|
||||
auto text_file = text_dump_filename("run0");
|
||||
auto binary_file = binary_dump_filename("run0");
|
||||
|
||||
generate_text_and_binary_dump(text_file, binary_file, "", 0);
|
||||
|
||||
@ -329,8 +344,8 @@ TEST_F(DumpAtomTest, binary_with_units_run0)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto text_file = "dump_text_with_units_run0.melt";
|
||||
auto binary_file = "dump_binary_with_units_run0.melt.bin";
|
||||
auto text_file = text_dump_filename("with_units_run0");
|
||||
auto binary_file = binary_dump_filename("with_units_run0");
|
||||
|
||||
generate_text_and_binary_dump(text_file, binary_file, "scale no units yes", 0);
|
||||
|
||||
@ -350,8 +365,8 @@ TEST_F(DumpAtomTest, binary_with_time_run0)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto text_file = "dump_text_with_time_run0.melt";
|
||||
auto binary_file = "dump_binary_with_time_run0.melt.bin";
|
||||
auto text_file = text_dump_filename("with_time_run0");
|
||||
auto binary_file = binary_dump_filename("with_time_run0");
|
||||
|
||||
generate_text_and_binary_dump(text_file, binary_file, "scale no time yes", 0);
|
||||
|
||||
@ -371,8 +386,8 @@ TEST_F(DumpAtomTest, binary_triclinic_run0)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto text_file = "dump_text_tri_run0.melt";
|
||||
auto binary_file = "dump_binary_tri_run0.melt.bin";
|
||||
auto text_file = text_dump_filename("tri_run0");
|
||||
auto binary_file = binary_dump_filename("tri_run0");
|
||||
|
||||
enable_triclinic();
|
||||
generate_text_and_binary_dump(text_file, binary_file, "", 0);
|
||||
@ -393,8 +408,8 @@ TEST_F(DumpAtomTest, binary_triclinic_with_units_run0)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto text_file = "dump_text_tri_with_units_run0.melt";
|
||||
auto binary_file = "dump_binary_tri_with_units_run0.melt.bin";
|
||||
auto text_file = text_dump_filename("tri_with_units_run0");
|
||||
auto binary_file = binary_dump_filename("tri_with_units_run0");
|
||||
|
||||
enable_triclinic();
|
||||
generate_text_and_binary_dump(text_file, binary_file, "scale no units yes", 0);
|
||||
@ -415,8 +430,8 @@ TEST_F(DumpAtomTest, binary_triclinic_with_time_run0)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto text_file = "dump_text_tri_with_time_run0.melt";
|
||||
auto binary_file = "dump_binary_tri_with_time_run0.melt.bin";
|
||||
auto text_file = text_dump_filename("tri_with_time_run0");
|
||||
auto binary_file = binary_dump_filename("tri_with_time_run0");
|
||||
|
||||
enable_triclinic();
|
||||
generate_text_and_binary_dump(text_file, binary_file, "scale no time yes", 0);
|
||||
@ -437,8 +452,8 @@ TEST_F(DumpAtomTest, binary_triclinic_with_image_run0)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto text_file = "dump_text_tri_with_image_run0.melt";
|
||||
auto binary_file = "dump_binary_tri_with_image_run0.melt.bin";
|
||||
auto text_file = text_dump_filename("tri_with_image_run0");
|
||||
auto binary_file = binary_dump_filename("tri_with_image_run0");
|
||||
|
||||
enable_triclinic();
|
||||
generate_text_and_binary_dump(text_file, binary_file, "image yes", 0);
|
||||
@ -457,7 +472,7 @@ TEST_F(DumpAtomTest, binary_triclinic_with_image_run0)
|
||||
|
||||
TEST_F(DumpAtomTest, run1plus1)
|
||||
{
|
||||
auto dump_file = "dump_run1plus1.melt";
|
||||
auto dump_file = dump_filename("run1plus1");
|
||||
generate_dump(dump_file, "", 1);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -470,7 +485,7 @@ TEST_F(DumpAtomTest, run1plus1)
|
||||
|
||||
TEST_F(DumpAtomTest, run2)
|
||||
{
|
||||
auto dump_file = "dump_run2.melt";
|
||||
auto dump_file = dump_filename("run2");
|
||||
generate_dump(dump_file, "", 2);
|
||||
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
@ -480,7 +495,7 @@ TEST_F(DumpAtomTest, run2)
|
||||
|
||||
TEST_F(DumpAtomTest, rerun)
|
||||
{
|
||||
auto dump_file = "dump_rerun.melt";
|
||||
auto dump_file = dump_filename("rerun");
|
||||
HIDE_OUTPUT([&] {
|
||||
command("fix 1 all nve");
|
||||
});
|
||||
@ -508,38 +523,43 @@ TEST_F(DumpAtomTest, rerun)
|
||||
|
||||
TEST_F(DumpAtomTest, multi_file_run1)
|
||||
{
|
||||
auto dump_file = "dump_run1_*.melt";
|
||||
auto dump_file = dump_filename("run1_*");
|
||||
generate_dump(dump_file, "", 1);
|
||||
|
||||
ASSERT_FILE_EXISTS("dump_run1_0.melt");
|
||||
ASSERT_FILE_EXISTS("dump_run1_1.melt");
|
||||
ASSERT_EQ(count_lines("dump_run1_0.melt"), 41);
|
||||
ASSERT_EQ(count_lines("dump_run1_1.melt"), 41);
|
||||
delete_file("dump_run1_0.melt");
|
||||
delete_file("dump_run1_1.melt");
|
||||
auto run1_0 = dump_filename("run1_0");
|
||||
auto run1_1 = dump_filename("run1_1");
|
||||
ASSERT_FILE_EXISTS(run1_0);
|
||||
ASSERT_FILE_EXISTS(run1_1);
|
||||
ASSERT_EQ(count_lines(run1_0), 41);
|
||||
ASSERT_EQ(count_lines(run1_1), 41);
|
||||
delete_file(run1_0);
|
||||
delete_file(run1_1);
|
||||
}
|
||||
|
||||
TEST_F(DumpAtomTest, per_processor_file_run1)
|
||||
{
|
||||
auto dump_file = "dump_run1_p%.melt";
|
||||
auto dump_file = dump_filename("run1_p%");
|
||||
generate_dump(dump_file, "", 1);
|
||||
|
||||
ASSERT_FILE_EXISTS("dump_run1_p0.melt");
|
||||
ASSERT_EQ(count_lines("dump_run1_p0.melt"), 82);
|
||||
delete_file("dump_run1_p0.melt");
|
||||
auto run1_p0 = dump_filename("run1_p0");
|
||||
ASSERT_FILE_EXISTS(run1_p0);
|
||||
ASSERT_EQ(count_lines(run1_p0), 82);
|
||||
delete_file(run1_p0);
|
||||
}
|
||||
|
||||
TEST_F(DumpAtomTest, per_processor_multi_file_run1)
|
||||
{
|
||||
auto dump_file = "dump_run1_p%_*.melt";
|
||||
auto dump_file = dump_filename("run1_p%_*");
|
||||
generate_dump(dump_file, "", 1);
|
||||
|
||||
ASSERT_FILE_EXISTS("dump_run1_p0_0.melt");
|
||||
ASSERT_FILE_EXISTS("dump_run1_p0_1.melt");
|
||||
ASSERT_EQ(count_lines("dump_run1_p0_0.melt"), 41);
|
||||
ASSERT_EQ(count_lines("dump_run1_p0_1.melt"), 41);
|
||||
delete_file("dump_run1_p0_0.melt");
|
||||
delete_file("dump_run1_p0_1.melt");
|
||||
auto run1_p0_0 = dump_filename("run1_p0_0");
|
||||
auto run1_p0_1 = dump_filename("run1_p0_1");
|
||||
ASSERT_FILE_EXISTS(run1_p0_0);
|
||||
ASSERT_FILE_EXISTS(run1_p0_1);
|
||||
ASSERT_EQ(count_lines(run1_p0_0), 41);
|
||||
ASSERT_EQ(count_lines(run1_p0_1), 41);
|
||||
delete_file(run1_p0_0);
|
||||
delete_file(run1_p0_1);
|
||||
}
|
||||
|
||||
TEST_F(DumpAtomTest, dump_modify_scale_invalid)
|
||||
@ -573,16 +593,17 @@ TEST_F(DumpAtomTest, dump_modify_invalid)
|
||||
|
||||
TEST_F(DumpAtomTest, write_dump)
|
||||
{
|
||||
auto reference = "dump_ref_run0.melt";
|
||||
auto dump_file = "write_dump_atom_run0.melt";
|
||||
auto reference = dump_filename("run0_ref");
|
||||
auto dump_file = fmt::format("write_{}", dump_filename("run*"));
|
||||
|
||||
BEGIN_HIDE_OUTPUT();
|
||||
command(fmt::format("dump id all atom 1 {}", reference));
|
||||
command("dump_modify id scale no units yes");
|
||||
command("run 0");
|
||||
command("write_dump all atom write_dump_atom_run*.melt modify scale no units yes");
|
||||
command(fmt::format("write_dump all atom {} modify scale no units yes", dump_file));
|
||||
END_HIDE_OUTPUT();
|
||||
|
||||
dump_file = fmt::format("write_{}", dump_filename("run0"));
|
||||
ASSERT_FILE_EXISTS(reference);
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
|
||||
@ -595,16 +616,17 @@ TEST_F(DumpAtomTest, binary_write_dump)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto reference = "dump_run0.melt.bin";
|
||||
auto dump_file = "write_dump_atom_run0_p0.melt.bin";
|
||||
auto reference = binary_dump_filename("write_run0_ref");
|
||||
auto dump_file = fmt::format("write_{}", binary_dump_filename("write_dump_atom_run*_p%"));
|
||||
|
||||
BEGIN_HIDE_OUTPUT();
|
||||
command(fmt::format("dump id all atom 1 {}", reference));
|
||||
command("dump_modify id scale no units yes");
|
||||
command("run 0");
|
||||
command("write_dump all atom write_dump_atom_run*_p%.melt.bin modify scale no units yes");
|
||||
command(fmt::format("write_dump all atom {} modify scale no units yes", dump_file));
|
||||
END_HIDE_OUTPUT();
|
||||
|
||||
dump_file = fmt::format("write_{}", binary_dump_filename("write_dump_atom_run0_p0"));
|
||||
ASSERT_FILE_EXISTS(reference);
|
||||
ASSERT_FILE_EXISTS(dump_file);
|
||||
|
||||
|
||||
@ -37,6 +37,21 @@ public:
|
||||
END_HIDE_OUTPUT();
|
||||
}
|
||||
|
||||
std::string dump_filename(std::string ident)
|
||||
{
|
||||
return fmt::format("dump_{}_{}.melt", dump_style, ident);
|
||||
}
|
||||
|
||||
std::string text_dump_filename(std::string ident)
|
||||
{
|
||||
return fmt::format("dump_{}_text_{}.melt", dump_style, ident);
|
||||
}
|
||||
|
||||
std::string binary_dump_filename(std::string ident)
|
||||
{
|
||||
return fmt::format("dump_{}_binary_{}.melt.bin", dump_style, ident);
|
||||
}
|
||||
|
||||
void generate_dump(std::string dump_file, std::string fields, std::string dump_modify_options,
|
||||
int ntimesteps)
|
||||
{
|
||||
@ -87,7 +102,7 @@ public:
|
||||
|
||||
TEST_F(DumpCustomTest, run1)
|
||||
{
|
||||
auto dump_file = "dump_custom_run1.melt";
|
||||
auto dump_file = dump_filename("run1");
|
||||
auto fields =
|
||||
"id type proc procp1 mass x y z ix iy iz xs ys zs xu yu zu xsu ysu zsu vx vy vz fx fy fz";
|
||||
|
||||
@ -105,7 +120,7 @@ TEST_F(DumpCustomTest, run1)
|
||||
|
||||
TEST_F(DumpCustomTest, thresh_run0)
|
||||
{
|
||||
auto dump_file = "dump_custom_thresh_run0.melt";
|
||||
auto dump_file = dump_filename("thresh_run0");
|
||||
auto fields = "id type x y z";
|
||||
|
||||
generate_dump(dump_file, fields, "units yes thresh x < 1 thresh y < 1 thresh z < 1", 0);
|
||||
@ -126,7 +141,7 @@ TEST_F(DumpCustomTest, compute_run0)
|
||||
command("compute comp all property/atom x y z");
|
||||
END_HIDE_OUTPUT();
|
||||
|
||||
auto dump_file = "dump_custom_compute_run0.melt";
|
||||
auto dump_file = dump_filename("compute_run0");
|
||||
auto fields = "id type x y z c_comp[1] c_comp[2] c_comp[3]";
|
||||
|
||||
generate_dump(dump_file, fields, "units yes", 0);
|
||||
@ -149,7 +164,7 @@ TEST_F(DumpCustomTest, fix_run0)
|
||||
command("fix numdiff all numdiff 1 0.0001");
|
||||
END_HIDE_OUTPUT();
|
||||
|
||||
auto dump_file = "dump_custom_compute_run0.melt";
|
||||
auto dump_file = dump_filename("fix_run0");
|
||||
auto fields = "id x y z f_numdiff[1] f_numdiff[2] f_numdiff[3]";
|
||||
|
||||
generate_dump(dump_file, fields, "units yes", 0);
|
||||
@ -171,7 +186,7 @@ TEST_F(DumpCustomTest, custom_run0)
|
||||
command("compute 1 all property/atom i_flag1 d_flag2");
|
||||
END_HIDE_OUTPUT();
|
||||
|
||||
auto dump_file = "dump_custom_custom_run0.melt";
|
||||
auto dump_file = dump_filename("custom_run0");
|
||||
auto fields = "id x y z i_flag1 d_flag2";
|
||||
|
||||
generate_dump(dump_file, fields, "units yes", 0);
|
||||
@ -190,8 +205,8 @@ TEST_F(DumpCustomTest, binary_run1)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto text_file = "dump_custom_text_run1.melt";
|
||||
auto binary_file = "dump_custom_binary_run1.melt.bin";
|
||||
auto text_file = text_dump_filename("run1");
|
||||
auto binary_file = binary_dump_filename("run1");
|
||||
auto fields = "id type proc x y z ix iy iz xs ys zs xu yu zu xsu ysu zsu vx vy vz fx fy fz";
|
||||
|
||||
generate_text_and_binary_dump(text_file, binary_file, fields, "units yes", 1);
|
||||
@ -210,7 +225,7 @@ TEST_F(DumpCustomTest, binary_run1)
|
||||
|
||||
TEST_F(DumpCustomTest, triclinic_run1)
|
||||
{
|
||||
auto dump_file = "dump_custom_tri_run1.melt";
|
||||
auto dump_file = dump_filename("tri_run1");
|
||||
auto fields = "id type proc x y z ix iy iz xs ys zs xu yu zu xsu ysu zsu vx vy vz fx fy fz";
|
||||
|
||||
enable_triclinic();
|
||||
@ -231,8 +246,8 @@ TEST_F(DumpCustomTest, binary_triclinic_run1)
|
||||
{
|
||||
if (!BINARY2TXT_BINARY) GTEST_SKIP();
|
||||
|
||||
auto text_file = "dump_custom_tri_text_run1.melt";
|
||||
auto binary_file = "dump_custom_tri_binary_run1.melt.bin";
|
||||
auto text_file = text_dump_filename("tri_run1");
|
||||
auto binary_file = binary_dump_filename("tri_run1");
|
||||
auto fields = "id type proc x y z xs ys zs xsu ysu zsu vx vy vz fx fy fz";
|
||||
|
||||
enable_triclinic();
|
||||
@ -258,7 +273,7 @@ TEST_F(DumpCustomTest, with_variable_run1)
|
||||
command("variable p atom (c_1%10)+1");
|
||||
END_HIDE_OUTPUT();
|
||||
|
||||
auto dump_file = "dump_custom_with_variable_run1.melt";
|
||||
auto dump_file = dump_filename("with_variable_run1");
|
||||
auto fields = "id type x y z v_p";
|
||||
|
||||
generate_dump(dump_file, fields, "units yes", 1);
|
||||
@ -275,7 +290,7 @@ TEST_F(DumpCustomTest, with_variable_run1)
|
||||
|
||||
TEST_F(DumpCustomTest, run1plus1)
|
||||
{
|
||||
auto dump_file = "dump_custom_run1plus1.melt";
|
||||
auto dump_file = dump_filename("run1plus1");
|
||||
auto fields = "id type x y z";
|
||||
|
||||
generate_dump(dump_file, fields, "units yes", 1);
|
||||
@ -292,7 +307,7 @@ TEST_F(DumpCustomTest, run1plus1)
|
||||
|
||||
TEST_F(DumpCustomTest, run2)
|
||||
{
|
||||
auto dump_file = "dump_custom_run2.melt";
|
||||
auto dump_file = dump_filename("run2");
|
||||
auto fields = "id type x y z";
|
||||
generate_dump(dump_file, fields, "", 2);
|
||||
|
||||
@ -303,7 +318,7 @@ TEST_F(DumpCustomTest, run2)
|
||||
|
||||
TEST_F(DumpCustomTest, rerun)
|
||||
{
|
||||
auto dump_file = "dump_rerun.melt";
|
||||
auto dump_file = dump_filename("rerun");
|
||||
auto fields = "id type xs ys zs";
|
||||
|
||||
HIDE_OUTPUT([&] {
|
||||
|
||||
Reference in New Issue
Block a user