ElectricField base Class and Homogene Class with tests
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
#include "catch.hpp"
|
||||
|
||||
#include "vec3_container.hpp"
|
||||
#include "Homogene.h"
|
||||
|
||||
SCENARIO("Test the vec3_container Constructor with Electric Field class", "[vec3_container.hpp]") {
|
||||
GIVEN("Vec3 Container initilazed with a homogene electric field") {
|
||||
Homogene electric_field(vec3(5,0,0));
|
||||
Vec3_Container efeld(10, 10, 10, electric_field);
|
||||
//vec3 value(5,0,0);
|
||||
//vec3 value = blitz::TinyVector<double, 3>(5,0,0)
|
||||
|
||||
REQUIRE(efeld.get_data(vec3(0, 0, 0))[0] == 5 );
|
||||
REQUIRE(efeld.get_data(vec3(0, 0, 0))[1] == 0 );
|
||||
REQUIRE(efeld.get_data(vec3(0, 0, 0))[2] == 0 );
|
||||
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user