Source code structuration and Unit Tests

html version of this document is produced with docutils:

rst2html < doc.txt > doc.html

This document corresponds to SALOME2 3.2.0

Contents

WORK in PROGRESS, INCOMPLETE DOCUMENT

You will find here general information on code directories structure, unit tests associated to the different kind of classes, and how to run the unit tests.

1   SALOME KERNEL source code structuration

1.1   General structure of KERNEL_SRC

KERNEL_SRC
Some README files and configuration tools for build
KERNEL_SRC/adm_local
Part of the configuration files, other modules have a directory with the same name. Not used in KERNEL.
KERNEL_SRC/bin
Python and shell scripts used at run time. Kit to install a SALOME Application.
KERNEL_SRC/doc
Kit for KERNEL end user documentation production: public interfaces, Python, CORBA. Integrator and Developper documentation.
KERNEL_SRC/idl
All CORBA interfaces from KERNEL are regrouped here.
KERNEL_SRC/resources
Configuration files for servers (examples). Interfaces definitions for KERNEL test components.
KERNEL_SRC/salome_adm
Configuration files used by autotools (M4 macros & co.)
KERNEL_SRC/src
The source code (C++ and Python)

1.2   Directory src: C++ and Python source code

1.2.2   Basic CORBA services

Logger
A CORBA server that collects the trace messages from differents CORBA process.
SALOMETraceCollector
A multithread trace system derived from SALOMELocalTrace, that sends messages to Logger server via CORBA.
Utils
A set of general purpose services related to CORBA, such as basic CORBA exception system. See also Basics directory above.
NamingService
C++ and Python interfaces to name, store and retrieve CORBA objects
GenericObj
A generic CORBA interface for CORBA objects, to count distributed references, and to allow destruction by client.

1.2.3   Miscellaneous CORBA servers

Registry
Implements SALOME_registry.idl. Provides a CORBA server library and a separate server program.
ModuleCatalog
Implements SALOME_moduleCatalog.idl. Provide a CORBA server library and separate server and client programs.
ModuleGenerator
Tool to generate a module catalog from CORBA idl
ResourcesManager
library included in container server
Notification
library included in differents servers (container)

NOTIFICATION_SWIG

1.2.4   CORBA Containers for SALOME Modules

Container

TestContainer

LifeCycleCORBA

LifeCycleCORBA_SWIG

1.2.7   Efficient CORBA transfer services

Communication

Communication_SWIG

1.2.8   A Parallel container with MPI

MPIContainer

TestMPIContainer

2   Tools and principles used for Unit testing

TO BE COMPLETED

Unit Testing rely on cppunit package for C++ testing, and on unittest module for Python. See these products for general principles of unit testing.

The cppunit package is optional. When the prerequisite is detected, the unit tests are compiled.

Unit Tests sources are in directories Test under the src/directories containing the classes to test.

Test are ordered following the order of directories given above.

Tests can be run as a whole, or for a particular directory. In this case, only a partial test is run (the classes to test, and the classes used, i.e. the preceding test directories).

Today, only some tests are written as an example. There are not yet python scripts in KERNEL_SRC, but it's a matter of days, there are working scripts to test LifeCycleCORBA_SWIG interface.


General KERNEL documentation End User KERNEL Doxygen documentation