Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
itischler
lbmpy
Commits
adffe684
Commit
adffe684
authored
Feb 19, 2021
by
Markus Holzer
Committed by
Michael Kuron
Feb 19, 2021
Browse files
Enable all test cases in windows pipeline
parent
a18d80af
Changes
5
Hide whitespace changes
Inline
Side-by-side
.gitlab-ci.yml
View file @
adffe684
...
...
@@ -96,12 +96,15 @@ minimal-windows:
tags
:
-
win
script
:
-
export NUM_CORES=$(nproc --all)
-
export MPLBACKEND=Agg
-
source /cygdrive/c/Users/build/Miniconda3/Scripts/activate
-
source activate pystencils
-
pip install git+https://gitlab-ci-token:${CI_JOB_TOKEN}@i10git.cs.fau.de/pycodegen/pystencils.git@master#egg=pystencils
-
env
-
pip list
-
python -c "import numpy"
-
py
thon setup.py quicktest
-
py
.test -v -n $NUM_CORES -m "not (notebook or longrun)"
ubuntu
:
stage
:
test
...
...
lbmpy_tests/test_n_phase_boyer_noncoupled.ipynb
→
lbmpy_tests/
phasefield/
test_n_phase_boyer_noncoupled.ipynb
View file @
adffe684
File moved
lbmpy_tests/test_phase_field_scenarios.py
→
lbmpy_tests/
phasefield/
test_phase_field_scenarios.py
View file @
adffe684
...
...
@@ -11,6 +11,7 @@ from lbmpy.phasefield.experiments2D import (
create_two_drops_between_phases
,
write_phase_field_picture_sequence
,
write_phase_velocity_picture_sequence
)
from
lbmpy.phasefield.phasefieldstep
import
PhaseFieldStep
from
lbmpy.phasefield.scenarios
import
*
from
pystencils
import
make_slice
...
...
@@ -47,3 +48,31 @@ def test_falling_drop():
file_pattern
=
os
.
path
.
join
(
tmp_dir
,
"output_%d.png"
)
write_phase_velocity_picture_sequence
(
sc
,
file_pattern
,
total_steps
=
200
)
assert
np
.
isfinite
(
np
.
max
(
sc
.
phi
[:,
:,
:]))
def
test_setup
():
domain_size
=
(
30
,
15
)
scenarios
=
[
create_three_phase_model
(
domain_size
=
domain_size
,
include_rho
=
True
),
#create_three_phase_model(domain_size=domain_size, include_rho=False),
create_n_phase_model_penalty_term
(
domain_size
=
domain_size
,
num_phases
=
4
),
]
for
i
,
sc
in
enumerate
(
scenarios
):
print
(
"Testing scenario"
,
i
)
sc
.
set_concentration
(
make_slice
[:,
:
0.5
],
[
1
,
0
,
0
])
sc
.
set_concentration
(
make_slice
[:,
0.5
:],
[
0
,
1
,
0
])
sc
.
set_concentration
(
make_slice
[
0.4
:
0.6
,
0.4
:
0.6
],
[
0
,
0
,
1
])
sc
.
set_pdf_fields_from_macroscopic_values
()
sc
.
run
(
10
)
def
test_fd_cahn_hilliard
():
sc
=
create_n_phase_model_penalty_term
(
domain_size
=
(
100
,
50
),
num_phases
=
3
,
solve_cahn_hilliard_with_finite_differences
=
True
)
sc
.
set_concentration
(
make_slice
[:,
0.5
:],
[
1
,
0
,
0
])
sc
.
set_concentration
(
make_slice
[:,
:
0.5
],
[
0
,
1
,
0
])
sc
.
set_concentration
(
make_slice
[
0.3
:
0.7
,
0.3
:
0.7
],
[
0
,
0
,
1
])
sc
.
set_pdf_fields_from_macroscopic_values
()
sc
.
run
(
100
)
assert
np
.
isfinite
(
np
.
max
(
sc
.
concentration
[:,
:]))
lbmpy_tests/test_phasefield.py
→
lbmpy_tests/
phasefield/
test_phasefield.py
View file @
adffe684
File moved
lbmpy_tests/test_phasefield_scenarios.py
deleted
100644 → 0
View file @
a18d80af
from
lbmpy.phasefield.scenarios
import
*
from
pystencils
import
make_slice
def
test_setup
():
domain_size
=
(
30
,
15
)
scenarios
=
[
create_three_phase_model
(
domain_size
=
domain_size
,
include_rho
=
True
),
#create_three_phase_model(domain_size=domain_size, include_rho=False),
create_n_phase_model_penalty_term
(
domain_size
=
domain_size
,
num_phases
=
4
),
]
for
i
,
sc
in
enumerate
(
scenarios
):
print
(
"Testing scenario"
,
i
)
sc
.
set_concentration
(
make_slice
[:,
:
0.5
],
[
1
,
0
,
0
])
sc
.
set_concentration
(
make_slice
[:,
0.5
:],
[
0
,
1
,
0
])
sc
.
set_concentration
(
make_slice
[
0.4
:
0.6
,
0.4
:
0.6
],
[
0
,
0
,
1
])
sc
.
set_pdf_fields_from_macroscopic_values
()
sc
.
run
(
10
)
def
test_fd_cahn_hilliard
():
sc
=
create_n_phase_model_penalty_term
(
domain_size
=
(
100
,
50
),
num_phases
=
3
,
solve_cahn_hilliard_with_finite_differences
=
True
)
sc
.
set_concentration
(
make_slice
[:,
0.5
:],
[
1
,
0
,
0
])
sc
.
set_concentration
(
make_slice
[:,
:
0.5
],
[
0
,
1
,
0
])
sc
.
set_concentration
(
make_slice
[
0.3
:
0.7
,
0.3
:
0.7
],
[
0
,
0
,
1
])
sc
.
set_pdf_fields_from_macroscopic_values
()
sc
.
run
(
100
)
assert
np
.
isfinite
(
np
.
max
(
sc
.
concentration
[:,
:]))
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment