Skip to content
Snippets Groups Projects
Commit 0eeebeaa authored by Anna Wellmann's avatar Anna Wellmann
Browse files

Merge branch 'develop' into reorderDistributions

parents 5a406937 147d658e
No related branches found
No related tags found
1 merge request!126Fix bug in slip boundary condition and do some cleanup
# these two parameters need to be defined in each config file
Path = /output/path
GridPath = /path/to/grid
\ No newline at end of file
...@@ -28,7 +28,7 @@ protected: ...@@ -28,7 +28,7 @@ protected:
void SetUp() override void SetUp() override
{ {
para = std::make_shared<Parameter>(1, 0); para = std::make_shared<Parameter>();
para->setMaxLevel(level + 1); // setMaxLevel resizes parH para->setMaxLevel(level + 1); // setMaxLevel resizes parH
para->initLBMSimulationParameter(); // init parH para->initLBMSimulationParameter(); // init parH
......
# these two parameters need to be defined in each config file
Path = /output/path
GridPath = /path/to/grid
\ No newline at end of file
...@@ -214,7 +214,7 @@ private: ...@@ -214,7 +214,7 @@ private:
void SetUp() override void SetUp() override
{ {
para = std::make_shared<Parameter>(1, 0); para = std::make_shared<Parameter>();
testSubject = createTestSubjectFCBorderBulk(); testSubject = createTestSubjectFCBorderBulk();
} }
}; };
...@@ -313,7 +313,7 @@ private: ...@@ -313,7 +313,7 @@ private:
void SetUp() override void SetUp() override
{ {
para = std::make_shared<Parameter>(1, 0); para = std::make_shared<Parameter>();
testSubject = createTestSubjectReorderSendIndices(); testSubject = createTestSubjectReorderSendIndices();
}; };
}; };
......
...@@ -45,14 +45,11 @@ ...@@ -45,14 +45,11 @@
#include "VirtualFluids_GPU_export.h" #include "VirtualFluids_GPU_export.h"
struct curandStateXORWOW; struct curandStateXORWOW;
typedef struct curandStateXORWOW curandState; using curandState = struct curandStateXORWOW;
namespace vf namespace vf:: basics
{
namespace basics
{ {
class ConfigurationFile; class ConfigurationFile;
} }
} // namespace vf
class CudaStreamManager; class CudaStreamManager;
//! \struct LBMSimulationParameter //! \struct LBMSimulationParameter
...@@ -377,8 +374,8 @@ struct LBMSimulationParameter { ...@@ -377,8 +374,8 @@ struct LBMSimulationParameter {
class VIRTUALFLUIDS_GPU_EXPORT Parameter class VIRTUALFLUIDS_GPU_EXPORT Parameter
{ {
public: public:
Parameter(const vf::basics::ConfigurationFile &configData, int numberOfProcesses, int myId); Parameter(const vf::basics::ConfigurationFile &configData, const int numberOfProcesses = 1, const int myId = 0);
Parameter(int numberOfProcesses, int myId); Parameter(const int numberOfProcesses = 1, const int myId = 0);
~Parameter(); ~Parameter();
void initLBMSimulationParameter(); void initLBMSimulationParameter();
......
...@@ -39,7 +39,7 @@ TEST(ParameterTest, check_all_Parameter_CanBePassedToConstructor) ...@@ -39,7 +39,7 @@ TEST(ParameterTest, check_all_Parameter_CanBePassedToConstructor)
vf::basics::ConfigurationFile config; vf::basics::ConfigurationFile config;
config.load(filePath.string()); config.load(filePath.string());
Parameter para(config, 1, 0); Parameter para(config);
// test optional parameter // test optional parameter
EXPECT_THAT(para.getOutputPath(), testing::Eq("/output/path/")); EXPECT_THAT(para.getOutputPath(), testing::Eq("/output/path/"));
...@@ -151,7 +151,7 @@ TEST(ParameterTest, check_all_Parameter_CanBePassedToConstructor) ...@@ -151,7 +151,7 @@ TEST(ParameterTest, check_all_Parameter_CanBePassedToConstructor)
TEST(ParameterTest, defaultGridPath) TEST(ParameterTest, defaultGridPath)
{ {
Parameter para(1, 0); Parameter para;
EXPECT_THAT(para.getGridPath(), testing::Eq("grid/")); EXPECT_THAT(para.getGridPath(), testing::Eq("grid/"));
EXPECT_THAT(para.getConcentration(), testing::Eq("grid/conc.dat")); EXPECT_THAT(para.getConcentration(), testing::Eq("grid/conc.dat"));
} }
...@@ -190,7 +190,7 @@ TEST(ParameterTest, setGridPathOverridesConfigFile) ...@@ -190,7 +190,7 @@ TEST(ParameterTest, setGridPathOverridesConfigFile)
TEST(ParameterTest, userMissedSlash) TEST(ParameterTest, userMissedSlash)
{ {
Parameter para(1, 0); Parameter para;
para.setGridPath("gridPathTest"); para.setGridPath("gridPathTest");
EXPECT_THAT(para.getGridPath(), testing::Eq("gridPathTest/")); EXPECT_THAT(para.getGridPath(), testing::Eq("gridPathTest/"));
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment