1
0
Fork 0
mirror of https://github.com/gwm17/catima.git synced 2024-11-22 18:28:51 -05:00
This commit is contained in:
hrocho 2019-05-11 19:18:35 +02:00
parent 1dc5fa57e2
commit 7088148f5b
2 changed files with 11 additions and 9 deletions

View File

@ -49,10 +49,7 @@ const lest::test specification[] =
catima::Material graphite({ catima::Material graphite({
{12,6,1} {12,6,1}
}); });
catima::Config c1;
c1.z_effective = catima::z_eff_type::global;
catima::_storage.Reset(); catima::_storage.Reset();
EXPECT(catima::_storage.get_index()==0); EXPECT(catima::_storage.get_index()==0);
@ -76,12 +73,15 @@ const lest::test specification[] =
catima::_storage.Add(p,graphite); catima::_storage.Add(p,graphite);
EXPECT(catima::_storage.get_index()==2); EXPECT(catima::_storage.get_index()==2);
catima::Config c1;
c1.z_effective = catima::z_eff_type::global;
catima::_storage.Add(p,graphite, c1); catima::_storage.Add(p,graphite, c1);
EXPECT(catima::_storage.get_index()==3); EXPECT(catima::_storage.get_index()==3);
catima::_storage.Add(p,graphite); catima::_storage.Add(p,graphite);
EXPECT(catima::_storage.get_index()==3); EXPECT(catima::_storage.get_index()==3);
c1.z_effective = catima::z_eff_type::atima14; c1.z_effective = catima::z_eff_type::hubert;
catima::_storage.Add(p,graphite ,c1); catima::_storage.Add(p,graphite ,c1);
EXPECT(catima::_storage.get_index()==4); EXPECT(catima::_storage.get_index()==4);

View File

@ -160,19 +160,21 @@ const lest::test specification[] =
catima::Config c2; catima::Config c2;
catima::Config c3{catima::z_eff_type::none}; catima::Config c3{catima::z_eff_type::none};
catima::Config c4; catima::Config c4;
EXPECT(c1.z_effective == catima::z_eff_type::pierce_blann); EXPECT(c1.z_effective == catima::default_config.z_effective);
EXPECT(c1.z_effective != catima::z_eff_type::atima14);
EXPECT(c1==c2); EXPECT(c1==c2);
EXPECT( !(c1==c3)); EXPECT( !(c1==c3));
EXPECT(c1==c4); EXPECT(c1==c4);
c4.z_effective = catima::z_eff_type::global; c4.z_effective = catima::z_eff_type::global;
EXPECT(!(c1==c4)); EXPECT(!(c1==c4));
auto c5 = c4; auto c5 = c4;
EXPECT(c4==c5); EXPECT(c4==c5);
c4.z_effective = catima::z_eff_type::atima14;
c4.z_effective = catima::z_eff_type::hubert;
EXPECT(!(c4==c5) ); EXPECT(!(c4==c5) );
EXPECT(!(c4==c1)); EXPECT(!(c4==c1));
c4.z_effective = catima::z_eff_type::pierce_blann; c4.z_effective = catima::default_config.z_effective;
EXPECT(!(c5==c4)); EXPECT(!(c5==c4));
EXPECT((c1==c4)); EXPECT((c1==c4));
}, },