Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions testpackage/test_definitions_small.sh
Original file line number Diff line number Diff line change
Expand Up @@ -260,6 +260,16 @@ variable_components[${index}]="0 0 1 2 0 1 2"
single_cell[${index}]=1
((index+=1))

#######
# WRITE PATH TEST (26)
#######

# 26 write path test
test_name[${index}]="write_path_test"
single_cell[${index}]=1
((index+=1))


# choose tests to run (default: all tests)
run_tests=( )
for (( c=1; c<$index; c++ ))
Expand Down
13 changes: 13 additions & 0 deletions testpackage/tests/write_path_test/test_postproc.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/bin/sh

echo "--------------------------------------------------------------------------------------------"
echo " Testing write path "
echo "--------------------------------------------------------------------------------------------"

filepath_test="./testing/foo/bar/bulk.0000000.vlsv"
if [[ ! -f $filepath_test ]]; then
echo "File was not written to correct path at $filepath_test"
exit 1
fi
mv ./testing/foo/bar/* ./
echo "Write path test successful!"
3 changes: 3 additions & 0 deletions testpackage/tests/write_path_test/test_prelude.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#!/bin/sh

mkdir -p './testing/foo/bar'
103 changes: 103 additions & 0 deletions testpackage/tests/write_path_test/write_path_test.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,103 @@
dynamic_timestep = 0
project = MultiPeak
propagate_field = 0
propagate_vlasov_acceleration = 1
propagate_vlasov_translation = 0

ParticlePopulations = proton

[io]
diagnostic_write_interval = 1
write_initial_state = 0

system_write_t_interval = 180
system_write_file_name = foo/bar/bulk
system_write_path = ./testing
system_write_distribution_stride = 1
system_write_distribution_xline_stride = 0
system_write_distribution_yline_stride = 0
system_write_distribution_zline_stride = 0

[variables]
output = vg_rhom
output = fg_b
output = vg_pressure
output = populations_vg_v
output = fg_e
output = vg_rank
output = populations_vg_blocks
output = populations_vg_rho
#output = populations_vg_acceleration_subcycles

diagnostic = populations_vg_blocks
#diagnostic = vg_pressure
#diagnostic = populations_vg_rho
#diagnostic = populations_vg_rho_loss_adjust

[gridbuilder]
x_length = 1
y_length = 1
z_length = 1
x_min = 0.0
x_max = 1.0e6
y_min = 0.0
y_max = 1.0e6
z_min = 0
z_max = 1.0e6
t_max = 180
dt = 10.0

[proton_properties]
mass = 1
mass_units = PROTON
charge = 1

[proton_vspace]
vx_min = -2.0e6
vx_max = +2.0e6
vy_min = -2.0e6
vy_max = +2.0e6
vz_min = -2.0e6
vz_max = +2.0e6
vx_length = 50
vy_length = 50
vz_length = 50
[proton_sparse]
minValue = 1.0e-16

[boundaries]
periodic_x = yes
periodic_y = yes
periodic_z = yes

[MultiPeak]
#magnitude of 1.82206867e-10 gives a period of 360s, useful for testing...
Bx = 1.2e-10
By = 0.8e-10
Bz = 1.1135233442526334e-10
magXPertAbsAmp = 0
magYPertAbsAmp = 0
magZPertAbsAmp = 0

[proton_MultiPeak]
n = 2
Vx = 0.0
Vy = 5e5
Vz = 0.0
Tx = 500000.0
Ty = 500000.0
Tz = 500000.0
rho = 2000000.0
rhoPertAbsAmp = 0

Vx = 0.0
Vy = -5e5
Vz = 0.0
Tx = 100000.0
Ty = 100000.0
Tz = 100000.0
rho = 2000000
rhoPertAbsAmp = 0

[bailout]
velocity_space_wall_block_margin = 0
Loading