Commit 7e17e7b0 authored by Lynn Garren's avatar Lynn Garren
Browse files

beginnings of StdRandom test

parent 5b3b5cc8
......@@ -4,9 +4,9 @@
includedir = $(prefix)/include/CLHEP
# put . first so that CLHEP directory is built before anything else
SUBDIRS = StdHep . src examples
SUBDIRS = StdHep . src test examples
# list all subdirectories - for distribution and cleaning
DIST_SUBDIRS = StdHep . src examples
DIST_SUBDIRS = StdHep . src test examples
bin_SCRIPTS = StdHep-config
......
......@@ -52,6 +52,7 @@ AC_CONFIG_FILES([Makefile])
AC_CONFIG_FILES([StdHep/Makefile])
AC_CONFIG_FILES([StdHep/include/Makefile])
AC_CONFIG_FILES([src/Makefile])
AC_CONFIG_FILES([test/Makefile])
AC_CONFIG_FILES([StdHep-deps])
AC_CONFIG_FILES([StdHep/copy-header.pl], [chmod +x StdHep/copy-header.pl])
AC_CONFIG_FILES([examples/Makefile])
......
......@@ -28,6 +28,8 @@ StdRandom& StdRandom::operator=( const StdRandom & rhs )
return *this;
}
StdRandom:: ~StdRandom()
{ ; }
std::ostream& StdRandom::getStateAsStream( std::ostream & os ) const
{
......
# Applicable to each test program:
INCLUDES = -I$(top_builddir)/
# libraries to link, and whence
if BUILD_STATIC
LDADD = $(top_builddir)/src/libCLHEP-@PACKAGE@-@VERSION@.a \
$(top_builddir)/../HepMC/src/libCLHEP-HepMC-@VERSION@.a \
$(top_builddir)/../Random/src/libCLHEP-Random-@VERSION@.a
else
LIBS += $(MY_LD)$(top_builddir)/src
LDADD = $(top_builddir)/src/libCLHEP-@PACKAGE@-@VERSION@.$(SHEXT) \
$(top_builddir)/../HepMC/src/libCLHEP-HepMC-@VERSION@.$(SHEXT) \
$(top_builddir)/../Random/src/libCLHEP-Random-@VERSION@.$(SHEXT)
endif
# Identify executables needed during testing:
check_PROGRAMS = \
testStdRandom
#check_SCRIPTS =
# Identify test(s) to run when 'make check' is requested:
TESTS = \
testStdRandom
# Identify the test(s) for which failure is the intended outcome:
XFAIL_TESTS =
# Identify the dependencies on a per-test basis:
testStdRandom_SOURCES = testStdRandom.cc
# Identify input data file(s) and prototype output file(s):
#EXTRA_DIST =
# Identify generated file(s) to be removed when 'make clean' is requested:
CLEANFILES =
//////////////////////////////////////////////////////////////////////////
// Lynn Garren
//
// This program tests StdHep::StdRandom
//
//////////////////////////////////////////////////////////////////////////
#include <vector>
#include <iostream>
#include "CLHEP/StdHep/StdRandom.hh"
int main() {
int status=0;
StdHep::StdRandom rstate;
// fill and save an arbitrary vector just for grins
std::vector<unsigned long> rs;
for( int i=0; i<6; ++i) { rs.push_back(i*312); }
rstate.putState( rs );
rstate.print();
return status;
}
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment