Skip to content
Snippets Groups Projects
Commit 27e0d930 authored by Oliver Sander's avatar Oliver Sander
Browse files

rudimentary tests with just enough functionality to help me find all ISTLAllocator-isms

[[Imported from SVN: r1191]]
parent 133c9c2a
No related branches found
No related tags found
No related merge requests found
Makefile
Makefile.in
.deps
.libs
semantic.cache
indicestest
selectiontest
indexsettest
syncertest
bvectortest
matrixutilstest
gmon.out
vectorcommtest
matrixtest
matrixiteratortest
overlappingschwarztest
bcrsbuildtest
superlutest
mv
iotest
scaledidmatrixtest
basearraytest
vbvectortest
matrixredisttest
......@@ -18,7 +18,7 @@ if PARDISO
endif
# which tests where program to build and run are equal
NORMALTESTS = matrixutilstest matrixtest bvectortest \
NORMALTESTS = basearraytest matrixutilstest matrixtest bvectortest vbvectortest \
bcrsbuildtest matrixiteratortest mv iotest scaledidmatrixtest
# list of tests to run (indicestest is special case)
......@@ -46,10 +46,14 @@ if PARDISO
test_pardiso_LDADD = $(PARDISO_LIBS) $(LAPACK_LIBS) $(BLAS_LIBS) $(LIBS) $(FLIBS)
endif
basearraytest_SOURCES = basearraytest.cc
bcrsbuildtest_SOURCES = bcrsbuild.cc
bvectortest_SOURCES = bvectortest.cc
vbvectortest_SOURCES = vbvectortest.cc
matrixutilstest_SOURCES = matrixutilstest.cc laplacian.hh
matrixiteratortest_SOURCES = matrixiteratortest.cc
......
// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
// vi: set et ts=4 sw=2 sts=2:
#include "config.h"
#include <dune/istl/basearray.hh>
using namespace Dune;
int main()
{
base_array<double> v1(10);
base_array<double> v2 = v1;
// Test constructor from base_array_unmanaged
base_array<double> v3 = *(static_cast<base_array_unmanaged<double>*>(&v1));
v1.resize(20);
v1 = v2;
}
......@@ -288,7 +288,7 @@ int main()
matrix[i][j][k][l] = (i+j)/((double)(k*l)); // just anything
testSuperMatrix(matrix);
#if 0
// ////////////////////////////////////////////////////////////
// Test the BCRSMatrix class -- a sparse dynamic matrix
// ////////////////////////////////////////////////////////////
......@@ -397,4 +397,5 @@ int main()
sIdMatrix = 3.1459;
testMatrix(sIdMatrix, fvX, fvY);
#endif
}
// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
// vi: set et ts=4 sw=2 sts=2:
#include "config.h"
#include <dune/istl/vbvector.hh>
#include <dune/common/fvector.hh>
using namespace Dune;
int main()
{
VariableBlockVector<FieldVector<double,1> > v1;
VariableBlockVector<FieldVector<double,1> > v2 = v1;
VariableBlockVector<FieldVector<double,1> > v3(10);
VariableBlockVector<FieldVector<double,1> > v4(10,4);
v3.resize(20);
v4.resize(20,8);
v3 = v4;
VariableBlockVector<FieldVector<double,1> >::CreateIterator cIt = v1.createbegin();
for (; cIt!=v1.createend(); ++cIt)
int foo = 0;
}
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