Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BornAgain
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mlz
BornAgain
Commits
e391276e
Commit
e391276e
authored
3 years ago
by
Matthias Puchner
Browse files
Options
Downloads
Patches
Plain Diff
deactivate more Py tests with particle distribution
parent
4bd9a6bd
No related branches found
No related tags found
1 merge request
!65
Refactor Distribution Handling
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Tests/Examples/CMakeLists.txt
+20
-7
20 additions, 7 deletions
Tests/Examples/CMakeLists.txt
with
20 additions
and
7 deletions
Tests/Examples/CMakeLists.txt
+
20
−
7
View file @
e391276e
...
@@ -24,6 +24,15 @@ endforeach()
...
@@ -24,6 +24,15 @@ endforeach()
# Run unmodified examples, with plots under batch control
# Run unmodified examples, with plots under batch control
####################################################################################################
####################################################################################################
####################################################################################################
# The following tests contain a particle distribution, which is not supported right now. To keep
# the code for the time once it is newly implemented, the tests are only deactivated, not deleted.
####################################################################################################
set
(
ExampleNamesWithParticleDistribution
CylindersWithSizeDistribution
TwoTypesOfCylindersWithSizeDistribution
)
set
(
test_script
${
TOOL_DIR
}
/code/batch-plot.py
)
set
(
test_script
${
TOOL_DIR
}
/code/batch-plot.py
)
# Run one Python example.
# Run one Python example.
...
@@ -33,6 +42,11 @@ set(test_script ${TOOL_DIR}/code/batch-plot.py)
...
@@ -33,6 +42,11 @@ set(test_script ${TOOL_DIR}/code/batch-plot.py)
function
(
run_example example label
)
function
(
run_example example label
)
get_filename_component
(
name
${
example
}
NAME_WE
)
get_filename_component
(
name
${
example
}
NAME_WE
)
set
(
test_name Example.run.
${
name
}
)
set
(
test_name Example.run.
${
name
}
)
if
(
${
name
}
IN_LIST ExampleNamesWithParticleDistribution
)
message
(
"Test
${
test_name
}
contains ParticleDistribution and will not be executed"
)
return
()
endif
()
add_test
(
${
test_name
}
add_test
(
${
test_name
}
env PYTHONPATH=
${
CMAKE_LIBRARY_OUTPUT_DIRECTORY
}
env PYTHONPATH=
${
CMAKE_LIBRARY_OUTPUT_DIRECTORY
}
BORNAGAIN_EXAMPLE_DATA_DIR=
${
EXAMPLES_DIR
}
/data
BORNAGAIN_EXAMPLE_DATA_DIR=
${
EXAMPLES_DIR
}
/data
...
@@ -81,6 +95,10 @@ function(test_example example tolerance)
...
@@ -81,6 +95,10 @@ function(test_example example tolerance)
get_filename_component
(
EXAMPLE_DIR
${
script_path
}
DIRECTORY
)
get_filename_component
(
EXAMPLE_DIR
${
script_path
}
DIRECTORY
)
set
(
test_name Example.persist.
${
EXAMPLE_NAME
}
)
set
(
test_name Example.persist.
${
EXAMPLE_NAME
}
)
if
(
${
EXAMPLE_NAME
}
IN_LIST ExampleNamesWithParticleDistribution
)
message
(
"Test
${
test_name
}
contains ParticleDistribution and will not be executed"
)
return
()
endif
()
set
(
PYPERSIST_TOLERANCE
${
tolerance
}
)
set
(
PYPERSIST_TOLERANCE
${
tolerance
}
)
...
@@ -104,6 +122,7 @@ test_example(scatter2d/Cylinders 2e-10)
...
@@ -104,6 +122,7 @@ test_example(scatter2d/Cylinders 2e-10)
test_example
(
scatter2d/CylindersAndPrisms 2e-10
)
test_example
(
scatter2d/CylindersAndPrisms 2e-10
)
test_example
(
scatter2d/CylindersInAverageLayer 2e-10
)
test_example
(
scatter2d/CylindersInAverageLayer 2e-10
)
test_example
(
scatter2d/CylindersInBA 2e-10
)
test_example
(
scatter2d/CylindersInBA 2e-10
)
test_example
(
scatter2d/CylindersWithSizeDistribution 2e-10
)
test_example
(
scatter2d/DetectorResolutionFunction 2e-10
)
test_example
(
scatter2d/DetectorResolutionFunction 2e-10
)
test_example
(
scatter2d/DodecahedraSAS.py 2e-10
)
test_example
(
scatter2d/DodecahedraSAS.py 2e-10
)
test_example
(
scatter2d/HalfSpheresInAverageTopLayer 2e-10
)
test_example
(
scatter2d/HalfSpheresInAverageTopLayer 2e-10
)
...
@@ -118,6 +137,7 @@ test_example(scatter2d/RectangularGrating 0.5)
...
@@ -118,6 +137,7 @@ test_example(scatter2d/RectangularGrating 0.5)
test_example
(
scatter2d/RotatedPyramids 2e-10
)
test_example
(
scatter2d/RotatedPyramids 2e-10
)
test_example
(
scatter2d/SpheresAtHexLattice 2e-10
)
test_example
(
scatter2d/SpheresAtHexLattice 2e-10
)
test_example
(
scatter2d/TriangularRipple 2e-10
)
test_example
(
scatter2d/TriangularRipple 2e-10
)
test_example
(
scatter2d/TwoTypesOfCylindersWithSizeDistribution 2e-10
)
test_example
(
specular/AlternatingLayers 2e-10
)
test_example
(
specular/AlternatingLayers 2e-10
)
test_example
(
specular/BeamAngularDivergence 2e-10
)
test_example
(
specular/BeamAngularDivergence 2e-10
)
...
@@ -130,10 +150,3 @@ test_example(varia/DepthProbe 2e-10)
...
@@ -130,10 +150,3 @@ test_example(varia/DepthProbe 2e-10)
test_example
(
varia/Interference1DLattice 1.5
)
test_example
(
varia/Interference1DLattice 1.5
)
test_example
(
varia/OffSpecularSimulation 2e-10
)
test_example
(
varia/OffSpecularSimulation 2e-10
)
####################################################################################################
# The following tests contain a particle distribution, which is not supported right now. To keep
# the code for the time once it is newly implemented, the tests are only commented, not deleted.
####################################################################################################
#
# test_example(scatter2d/CylindersWithSizeDistribution 2e-10)
# test_example(scatter2d/TwoTypesOfCylindersWithSizeDistribution 2e-10)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment