From: André Ribes Date: Wed, 16 Jun 2010 10:00:27 +0000 (+0200) Subject: - Ajout des tests dans l'installation X-Git-Tag: V6_4_0rc3~144 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=d61c06beb36c119ec089a04669f0b871e0bb73bf;p=modules%2Fadao.git - Ajout des tests dans l'installation - test: DATASSIM -> ADAO --- diff --git a/adm_local/make_common_starter.am b/adm_local/make_common_starter.am index f02b90c..7bb83d1 100644 --- a/adm_local/make_common_starter.am +++ b/adm_local/make_common_starter.am @@ -12,6 +12,9 @@ salomeidldir = $(prefix)/idl/salome # Directory for installing resource files salomeresdir = $(prefix)/share/salome/resources/${MODULE_NAME} +# Directory for installing tests files +testsdir = $(prefix)/tests + # Directories for installing admin files admlocaldir = $(prefix)/adm_local admlocalunixdir = $(admlocaldir)/unix diff --git a/configure.ac b/configure.ac index 7b4e293..7859ba0 100644 --- a/configure.ac +++ b/configure.ac @@ -74,6 +74,9 @@ AC_CONFIG_FILES([ src/daSalome/daGUI/daGuiImpl/Makefile src/daSalome/daGUI/daEficasWrapper/Makefile src/daSalome/daGUI/daEficasWrapper/eficasWrapper.py + src/tests/Makefile + src/tests/daSalome/Makefile + src/tests/daSalome/test000_Blue_AnalysisFile.py bin/Makefile bin/qtEficas_adao_study.py ]) diff --git a/src/Makefile.am b/src/Makefile.am index 6836443..6998b32 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1 +1 @@ -SUBDIRS = daComposant daSalome daEficas +SUBDIRS = daComposant daSalome daEficas tests diff --git a/src/daEficas/prefs_ADAO.py.in b/src/daEficas/prefs_ADAO.py.in new file mode 100644 index 0000000..801e5fa --- /dev/null +++ b/src/daEficas/prefs_ADAO.py.in @@ -0,0 +1,37 @@ +# -*- coding: utf-8 -*- +import os, sys + +print "import des prefs de Datassim" + +# Configuration de Eficas +# INSTALLDIR, REPINI est obligatoire +INSTALLDIR = "@EFICAS_DIR@" +sys.path[:0]=[INSTALLDIR] +# positionnee a repin au debut mise a jour dans configuration +REPINI=os.path.dirname(os.path.abspath(__file__)) + +# initialdir sert comme directory initial des QFileDialog +initialdir=os.environ["PWD"] +# Codage des strings qui accepte les accents (en remplacement de 'ascii') +encoding='iso-8859-1' +# lang indique la langue utilisée pour les chaines d'aide : fr ou ang +lang='fr' + + +# INSTALLDIR sert � localiser l'installation d'Eficas +#INSTALLDIR=os.path.join(REPINI,'..') + + + +# Acces a la documentation +#rep_cata = INSTALLDIR +#path_doc = os.path.join(rep_cata,'Doc') +#exec_acrobat = "/usr/bin/xpdf" +#savedir = os.environ['HOME'] + + +# OpenTURNS Python module +#OpenTURNS_path="/local00/home/dutka/OpenTURNS/trunk-cmake/build-autotools/install/lib/python2.4/site-packages" +# Choix des catalogues +#sys.path[:0]=[INSTALLDIR, OpenTURNS_path] + diff --git a/src/daEficas/prefs_DATASSIM.py.in b/src/daEficas/prefs_DATASSIM.py.in deleted file mode 100644 index 801e5fa..0000000 --- a/src/daEficas/prefs_DATASSIM.py.in +++ /dev/null @@ -1,37 +0,0 @@ -# -*- coding: utf-8 -*- -import os, sys - -print "import des prefs de Datassim" - -# Configuration de Eficas -# INSTALLDIR, REPINI est obligatoire -INSTALLDIR = "@EFICAS_DIR@" -sys.path[:0]=[INSTALLDIR] -# positionnee a repin au debut mise a jour dans configuration -REPINI=os.path.dirname(os.path.abspath(__file__)) - -# initialdir sert comme directory initial des QFileDialog -initialdir=os.environ["PWD"] -# Codage des strings qui accepte les accents (en remplacement de 'ascii') -encoding='iso-8859-1' -# lang indique la langue utilisée pour les chaines d'aide : fr ou ang -lang='fr' - - -# INSTALLDIR sert � localiser l'installation d'Eficas -#INSTALLDIR=os.path.join(REPINI,'..') - - - -# Acces a la documentation -#rep_cata = INSTALLDIR -#path_doc = os.path.join(rep_cata,'Doc') -#exec_acrobat = "/usr/bin/xpdf" -#savedir = os.environ['HOME'] - - -# OpenTURNS Python module -#OpenTURNS_path="/local00/home/dutka/OpenTURNS/trunk-cmake/build-autotools/install/lib/python2.4/site-packages" -# Choix des catalogues -#sys.path[:0]=[INSTALLDIR, OpenTURNS_path] - diff --git a/src/tests/Makefile.am b/src/tests/Makefile.am new file mode 100644 index 0000000..54b6585 --- /dev/null +++ b/src/tests/Makefile.am @@ -0,0 +1,2 @@ +SUBDIRS = daSalome + diff --git a/src/tests/daSalome/Makefile.am b/src/tests/daSalome/Makefile.am new file mode 100644 index 0000000..1d82459 --- /dev/null +++ b/src/tests/daSalome/Makefile.am @@ -0,0 +1,8 @@ +include $(top_srcdir)/adm_local/make_common_starter.am + +DATA_INST = \ + test000_Blue_AnalysisCode.py test000_Blue_AnalysisFile.py test000_Blue.py + +tests_DATA = ${DATA_INST} +EXTRA_DIST = test000_Blue_AnalysisCode.py test000_Blue_AnalysisFile.py.in test000_Blue.py + diff --git a/src/tests/daSalome/test000_Blue_AnalysisFile.py b/src/tests/daSalome/test000_Blue_AnalysisFile.py deleted file mode 100644 index 5e2531c..0000000 --- a/src/tests/daSalome/test000_Blue_AnalysisFile.py +++ /dev/null @@ -1,40 +0,0 @@ -#-*-coding:iso-8859-1-*- -study_config = {} -study_config["Name"] = "test000_Blue" -study_config["Algorithm"] = "Blue" - -Background_config = {} -Background_config["Data"] = "0,1,2" -Background_config["Type"] = "Vector" -Background_config["From"] = "String" -study_config["Background"] = Background_config - -BackgroundError_config = {} -BackgroundError_config["Data"] = "1 0 0;0 1 0;0 0 1" -BackgroundError_config["Type"] = "Matrix" -BackgroundError_config["From"] = "String" -study_config["BackgroundError"] = BackgroundError_config - -Observation_config = {} -Observation_config["Data"] = "0.5,1.5,2.5" -Observation_config["Type"] = "Vector" -Observation_config["From"] = "String" -study_config["Observation"] = Observation_config - -ObservationError_config = {} -ObservationError_config["Data"] = "1 0 0;0 1 0;0 0 1" -ObservationError_config["Type"] = "Matrix" -ObservationError_config["From"] = "String" -study_config["ObservationError"] = ObservationError_config - -ObservationOperator_config = {} -ObservationOperator_config["Data"] = "1 0 0;0 1 0;0 0 1" -ObservationOperator_config["Type"] = "Matrix" -ObservationOperator_config["From"] = "String" -study_config["ObservationOperator"] = ObservationOperator_config - -Analysis_config = {} -Analysis_config["Data"] = "/home/aribes/Projets/DATASSIM_SRC/src/tests/daSalome/test000_Blue_AnalysisCode.py" -Analysis_config["From"] = "File" -study_config["Analysis"] = Analysis_config - diff --git a/src/tests/daSalome/test000_Blue_AnalysisFile.py.in b/src/tests/daSalome/test000_Blue_AnalysisFile.py.in new file mode 100644 index 0000000..42dae9e --- /dev/null +++ b/src/tests/daSalome/test000_Blue_AnalysisFile.py.in @@ -0,0 +1,40 @@ +#-*-coding:iso-8859-1-*- +study_config = {} +study_config["Name"] = "test000_Blue" +study_config["Algorithm"] = "Blue" + +Background_config = {} +Background_config["Data"] = "0,1,2" +Background_config["Type"] = "Vector" +Background_config["From"] = "String" +study_config["Background"] = Background_config + +BackgroundError_config = {} +BackgroundError_config["Data"] = "1 0 0;0 1 0;0 0 1" +BackgroundError_config["Type"] = "Matrix" +BackgroundError_config["From"] = "String" +study_config["BackgroundError"] = BackgroundError_config + +Observation_config = {} +Observation_config["Data"] = "0.5,1.5,2.5" +Observation_config["Type"] = "Vector" +Observation_config["From"] = "String" +study_config["Observation"] = Observation_config + +ObservationError_config = {} +ObservationError_config["Data"] = "1 0 0;0 1 0;0 0 1" +ObservationError_config["Type"] = "Matrix" +ObservationError_config["From"] = "String" +study_config["ObservationError"] = ObservationError_config + +ObservationOperator_config = {} +ObservationOperator_config["Data"] = "1 0 0;0 1 0;0 0 1" +ObservationOperator_config["Type"] = "Matrix" +ObservationOperator_config["From"] = "String" +study_config["ObservationOperator"] = ObservationOperator_config + +Analysis_config = {} +Analysis_config["Data"] = "@prefix@/tests/daSalome/test000_Blue_AnalysisCode.py" +Analysis_config["From"] = "File" +study_config["Analysis"] = Analysis_config +