Commit e8596f33 authored by Vít Hanousek's avatar Vít Hanousek
Browse files

FIX CutDistributedMeshFunctionTest

parent 2196ee77
Loading
Loading
Loading
Loading
+7 −3
Original line number Diff line number Diff line
@@ -578,7 +578,7 @@ TEST(CutDistributedMeshFunction, 3D_2_Save)
            StaticVector<1,typename CutMeshType::IndexType>(4) );

   
   String FileName=String("/tmp/test-file.tnl");
   String FileName=String("test-file.tnl");
   if(inCut)
   {
       MeshFunction<CutMeshType> cutMeshFunction;
@@ -612,7 +612,8 @@ TEST(CutDistributedMeshFunction, 3D_2_Save)
       loadMeshFunctionptr.bind(globalCutGrid,loaddof);

        File file;
        file.open( FileName, IOMode::read );
        bool ok=file.open( FileName, IOMode::read );
        TNL_ASSERT_TRUE(ok,"Cannot open file");
        loadMeshFunctionptr.boundLoad(file);
        file.close();
 
@@ -630,9 +631,12 @@ TEST(CutDistributedMeshFunction, 3D_2_Save)
                fromEntity.refresh();
                outEntity.refresh();

                EXPECT_EQ(loadMeshFunctionptr.getValue(outEntity), (*linearFunctionPtr)(fromEntity)) << "Error in Left overlap";
                EXPECT_EQ(loadMeshFunctionptr.getValue(outEntity), (*linearFunctionPtr)(fromEntity)) << "Error at "<< i <<" "<< j;

            }

        EXPECT_EQ( std::remove( FileName.getString()) , 0 );
        EXPECT_EQ( std::remove( (FileName+String("-mesh.tnl")).getString()) , 0 );
      }
  
}