Skip to content
Snippets Groups Projects
Commit 2a758935 authored by Mads M. Pedersen's avatar Mads M. Pedersen
Browse files

test fixes

parent 35bee260
No related branches found
No related tags found
No related merge requests found
Pipeline #
File added
......@@ -148,13 +148,12 @@ class TestHtcFile(unittest.TestCase):
htcfile.add_mann_turbulence(30.1, 1.1, 3.3, 102, False)
s = """begin mann;
create_turb_parameters\t30.1 1.1 3.3 102 0;\tL, alfaeps, gamma, seed, highfrq compensation
filename_u\t./turb/mann_l30.1_ae1.10_g3.3_h0_4096x32x32_1.465x3.12x3.12_s0102u.turb;
filename_v\t./turb/mann_l30.1_ae1.10_g3.3_h0_4096x32x32_1.465x3.12x3.12_s0102v.turb;
filename_w\t./turb/mann_l30.1_ae1.10_g3.3_h0_4096x32x32_1.465x3.12x3.12_s0102w.turb;
box_dim_u\t4096 1.4652;
filename_u\t./turb/mann_l30.1_ae1.10_g3.3_h0_16384x32x32_0.366x3.12x3.12_s0102u.turb;
filename_v\t./turb/mann_l30.1_ae1.10_g3.3_h0_16384x32x32_0.366x3.12x3.12_s0102v.turb;
filename_w\t./turb/mann_l30.1_ae1.10_g3.3_h0_16384x32x32_0.366x3.12x3.12_s0102w.turb;
box_dim_u\t16384 0.3662;
box_dim_v\t32 3.2258;
box_dim_w\t32 3.2258;
std_scaling\t1 0.8 0.5;"""
box_dim_w\t32 3.2258;"""
for a, b in zip(s.split("\n"), str(htcfile.wind.mann).split("\n")):
self.assertEqual(a.strip(), b.strip())
self.assertEqual(htcfile.wind.turb_format[0], 1)
......@@ -163,15 +162,15 @@ class TestHtcFile(unittest.TestCase):
def test_add_turb_export(self):
htc = HTCFile()
htc.add_mann_turbulence(30.1, 1.1, 3.3, 102, False)
htc.set_time(100,700,0.02)
htc.set_time(100,700,0.01)
htc.add_turb_export()
s = """begin turb_export;
filename_u\texport_u.turb;
filename_v\texport_v.turb;
filename_w\texport_w.turb;
samplefrq\t7;
samplefrq\t3;
time_start\t100;
nsteps\t30000.0;
nsteps\t60000.0;
box_dim_v\t32 3.2258;
box_dim_w\t32 3.2258;
end turb_export;"""
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment