apply clang-format

This commit is contained in:
Axel Kohlmeyer
2022-09-10 03:21:28 -04:00
parent 4998c065da
commit ab899861d5
19 changed files with 158 additions and 116 deletions

View File

@ -2123,7 +2123,7 @@ TEST_F(AtomStyleTest, body_nparticle)
"12.0 0.0 12.0 0.0 0.0 0.0\n"
"0.0 1.0 0.0\n"
"0.0 -3.0 0.0\n";
FILE *fp = fopen("input_atom_styles.data", "w");
FILE *fp = fopen("input_atom_styles.data", "w");
fputs(data_file, fp);
fclose(fp);
BEGIN_HIDE_OUTPUT();
@ -4889,16 +4889,26 @@ TEST_F(AtomStyleTest, oxdna)
command("set atom 8 shape 1.173984503142341 1.173984503142341 1.173984503142341");
command("set atom 9 shape 1.173984503142341 1.173984503142341 1.173984503142341");
command("set atom 10 shape 1.173984503142341 1.173984503142341 1.173984503142341");
command("set atom 1 quat 0.120438343611269 -0.970540441176996 0.208676441957758 16.990727782866998");
command("set atom 2 quat 0.122039415796829 -0.068232256412985 0.990177125658213 40.001729435287870");
command("set atom 3 quat 0.052760168698289 0.030943512185297 0.998127679033382 69.627682451632380");
command("set atom 4 quat -0.037622918613871 0.030623545471522 0.998822664169035 97.038820280300570");
command("set atom 5 quat 0.055056042946138 0.077631917807377 0.995460756369964 137.7813218321917");
command("set atom 6 quat 0.931128471673637 -0.355724722922553 -0.080372201291206 166.2836226291888");
command("set atom 7 quat 0.753526078198930 -0.648440397941919 0.108275111595674 200.6802564250672");
command("set atom 8 quat 0.553942138074214 -0.829580511279186 0.070315595507185 192.0355407659524");
command("set atom 9 quat -0.373540155765431 0.913070802138105 -0.163613759548524 171.0789308260751");
command("set atom 10 quat 0.027515673832457 0.998248649922676 -0.052369080773879 161.2621224558284");
command("set atom 1 quat 0.120438343611269 -0.970540441176996 0.208676441957758 "
"16.990727782866998");
command("set atom 2 quat 0.122039415796829 -0.068232256412985 0.990177125658213 "
"40.001729435287870");
command(
"set atom 3 quat 0.052760168698289 0.030943512185297 0.998127679033382 69.627682451632380");
command("set atom 4 quat -0.037622918613871 0.030623545471522 0.998822664169035 "
"97.038820280300570");
command(
"set atom 5 quat 0.055056042946138 0.077631917807377 0.995460756369964 137.7813218321917");
command("set atom 6 quat 0.931128471673637 -0.355724722922553 -0.080372201291206 "
"166.2836226291888");
command(
"set atom 7 quat 0.753526078198930 -0.648440397941919 0.108275111595674 200.6802564250672");
command(
"set atom 8 quat 0.553942138074214 -0.829580511279186 0.070315595507185 192.0355407659524");
command("set atom 9 quat -0.373540155765431 0.913070802138105 -0.163613759548524 "
"171.0789308260751");
command("set atom 10 quat 0.027515673832457 0.998248649922676 -0.052369080773879 "
"161.2621224558284");
command("bond_style oxdna2/fene");
command("bond_coeff * 2.0 0.25 0.7564");
command("special_bonds lj 0 1 1");
@ -4910,14 +4920,24 @@ TEST_F(AtomStyleTest, oxdna)
command("create_bonds single/bond 1 7 8");
command("create_bonds single/bond 1 8 9");
command("create_bonds single/bond 1 9 10");
command("pair_style hybrid/overlay oxdna2/excv oxdna2/stk oxdna2/hbond oxdna2/xstk oxdna2/coaxstk oxdna2/dh");
command("pair_style hybrid/overlay oxdna2/excv oxdna2/stk oxdna2/hbond oxdna2/xstk "
"oxdna2/coaxstk oxdna2/dh");
command("pair_coeff * * oxdna2/excv 2.0 0.7 0.675 2.0 0.515 0.5 2.0 0.33 0.32");
command("pair_coeff * * oxdna2/stk seqdep 0.1 1.3523 2.6717 6.0 0.4 0.9 0.32 0.75 1.3 0 0.8 0.9 0 0.95 0.9 0 0.95 2.0 0.65 2.0 0.65");
command("pair_coeff * * oxdna2/hbond seqdep 0.0 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command("pair_coeff 1 4 oxdna2/hbond seqdep 1.0678 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command("pair_coeff 2 3 oxdna2/hbond seqdep 1.0678 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command("pair_coeff * * oxdna2/xstk 47.5 0.575 0.675 0.495 0.655 2.25 0.791592653589793 0.58 1.7 1.0 0.68 1.7 1.0 0.68 1.5 0 0.65 1.7 0.875 0.68 1.7 0.875 0.68");
command("pair_coeff * * oxdna2/coaxstk 58.5 0.4 0.6 0.22 0.58 2.0 2.891592653589793 0.65 1.3 0 0.8 0.9 0 0.95 0.9 0 0.95 40.0 3.116592653589793");
command("pair_coeff * * oxdna2/stk seqdep 0.1 1.3523 2.6717 6.0 0.4 0.9 0.32 0.75 1.3 0 0.8 "
"0.9 0 0.95 0.9 0 0.95 2.0 0.65 2.0 0.65");
command(
"pair_coeff * * oxdna2/hbond seqdep 0.0 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 "
"0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command(
"pair_coeff 1 4 oxdna2/hbond seqdep 1.0678 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 "
"0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command(
"pair_coeff 2 3 oxdna2/hbond seqdep 1.0678 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 "
"0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command("pair_coeff * * oxdna2/xstk 47.5 0.575 0.675 0.495 0.655 2.25 0.791592653589793 0.58 "
"1.7 1.0 0.68 1.7 1.0 0.68 1.5 0 0.65 1.7 0.875 0.68 1.7 0.875 0.68");
command("pair_coeff * * oxdna2/coaxstk 58.5 0.4 0.6 0.22 0.58 2.0 2.891592653589793 0.65 1.3 0 "
"0.8 0.9 0 0.95 0.9 0 0.95 40.0 3.116592653589793");
command("pair_coeff * * oxdna2/dh 0.1 0.2 0.815");
END_HIDE_OUTPUT();
@ -4974,14 +4994,24 @@ TEST_F(AtomStyleTest, oxdna)
command("bond_style oxdna2/fene");
command("bond_coeff * 2.0 0.25 0.7564");
command("special_bonds lj 0 1 1");
command("pair_style hybrid/overlay oxdna2/excv oxdna2/stk oxdna2/hbond oxdna2/xstk oxdna2/coaxstk oxdna2/dh");
command("pair_style hybrid/overlay oxdna2/excv oxdna2/stk oxdna2/hbond oxdna2/xstk "
"oxdna2/coaxstk oxdna2/dh");
command("pair_coeff * * oxdna2/excv 2.0 0.7 0.675 2.0 0.515 0.5 2.0 0.33 0.32");
command("pair_coeff * * oxdna2/stk seqdep 0.1 1.3523 2.6717 6.0 0.4 0.9 0.32 0.75 1.3 0 0.8 0.9 0 0.95 0.9 0 0.95 2.0 0.65 2.0 0.65");
command("pair_coeff * * oxdna2/hbond seqdep 0.0 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command("pair_coeff 1 4 oxdna2/hbond seqdep 1.0678 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command("pair_coeff 2 3 oxdna2/hbond seqdep 1.0678 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command("pair_coeff * * oxdna2/xstk 47.5 0.575 0.675 0.495 0.655 2.25 0.791592653589793 0.58 1.7 1.0 0.68 1.7 1.0 0.68 1.5 0 0.65 1.7 0.875 0.68 1.7 0.875 0.68");
command("pair_coeff * * oxdna2/coaxstk 58.5 0.4 0.6 0.22 0.58 2.0 2.891592653589793 0.65 1.3 0 0.8 0.9 0 0.95 0.9 0 0.95 40.0 3.116592653589793");
command("pair_coeff * * oxdna2/stk seqdep 0.1 1.3523 2.6717 6.0 0.4 0.9 0.32 0.75 1.3 0 0.8 "
"0.9 0 0.95 0.9 0 0.95 2.0 0.65 2.0 0.65");
command(
"pair_coeff * * oxdna2/hbond seqdep 0.0 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 "
"0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command(
"pair_coeff 1 4 oxdna2/hbond seqdep 1.0678 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 "
"0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command(
"pair_coeff 2 3 oxdna2/hbond seqdep 1.0678 8.0 0.4 0.75 0.34 0.7 1.5 0 0.7 1.5 0 0.7 1.5 0 "
"0.7 0.46 3.141592653589793 0.7 4.0 1.5707963267948966 0.45 4.0 1.5707963267948966 0.45");
command("pair_coeff * * oxdna2/xstk 47.5 0.575 0.675 0.495 0.655 2.25 0.791592653589793 0.58 "
"1.7 1.0 0.68 1.7 1.0 0.68 1.5 0 0.65 1.7 0.875 0.68 1.7 0.875 0.68");
command("pair_coeff * * oxdna2/coaxstk 58.5 0.4 0.6 0.22 0.58 2.0 2.891592653589793 0.65 1.3 0 "
"0.8 0.9 0 0.95 0.9 0 0.95 40.0 3.116592653589793");
command("pair_coeff * * oxdna2/dh 0.1 0.2 0.815");
ASSERT_THAT(std::string(lmp->atom->atom_style), Eq("hybrid"));

View File

@ -144,7 +144,7 @@ TEST_F(DumpCfgTest, no_unwrap_no_buffer_run0)
ASSERT_THAT(lines[0], Eq("Number of particles = 32"));
delete_file("dump_cfg_no_unwrap_no_buffer_run0.melt.cfg");
}
}
} // namespace LAMMPS_NS
int main(int argc, char **argv)
{

View File

@ -384,7 +384,7 @@ TEST_F(DumpCustomTest, rerun_bin)
ASSERT_NEAR(pe_2, pe_rerun, 1.0e-14);
delete_file(dump_file);
}
}
} // namespace LAMMPS_NS
int main(int argc, char **argv)
{
MPI_Init(&argc, &argv);

View File

@ -238,7 +238,7 @@ TEST_F(DumpLocalTest, triclinic_run0)
ASSERT_EQ(utils::split_words(lines[7]).size(), 3);
delete_file(dump_file);
}
}
} // namespace LAMMPS_NS
int main(int argc, char **argv)
{

View File

@ -387,7 +387,7 @@ TEST_F(DumpNetCDFTest, run0_mpi)
}
delete_file(dump_file);
}
}
} // namespace LAMMPS_NS
int main(int argc, char **argv)
{

View File

@ -57,8 +57,7 @@ constexpr int LAMMPS_NS::PairVashishta::NPARAMS_PER_LINE;
constexpr int LAMMPS_NS::PairTersoffTable::NPARAMS_PER_LINE;
#endif
class PotentialFileReaderTest : public LAMMPSTest {
};
class PotentialFileReaderTest : public LAMMPSTest {};
// open for native units
TEST_F(PotentialFileReaderTest, Sw_native)
@ -259,8 +258,7 @@ TEST_F(PotentialFileReaderTest, UnitConvert)
delete reader;
}
class OpenPotentialTest : public LAMMPSTest {
};
class OpenPotentialTest : public LAMMPSTest {};
// open for native units
TEST_F(OpenPotentialTest, Sw_native)