Changeset 2491 for inundation/pyvolution/test_data_manager.py
- Timestamp:
- Mar 8, 2006, 1:39:11 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
inundation/pyvolution/test_data_manager.py
r2305 r2491 2277 2277 elevation = domain.quantities['elevation'].vertex_values 2278 2278 domain.set_quantity('stage', elevation + h) 2279 #elevation = domain.get_quantity('elevation')2280 #domain.set_quantity('stage', elevation + h)2281 2279 2282 2280 domain.check_integrity() … … 2307 2305 bits = ['vertex_coordinates'] 2308 2306 for quantity in ['elevation']+domain.quantities_to_be_stored: 2309 bits.append(' quantities["%s"].get_integral()'%quantity)2310 bits.append('get_quantity("%s") '%quantity)2307 bits.append('get_quantity("%s").get_integral()' %quantity) 2308 bits.append('get_quantity("%s").get_values()' %quantity) 2311 2309 2312 2310 for bit in bits: … … 2368 2366 2369 2367 for quantity in ['elevation','xmomentum','ymomentum']:#+domain.quantities_to_be_stored: 2370 bits.append(' quantities["%s"].get_integral()'%quantity)2371 bits.append('get_quantity("%s") '%quantity)2368 bits.append('get_quantity("%s").get_integral()' %quantity) 2369 bits.append('get_quantity("%s").get_values()' %quantity) 2372 2370 2373 2371 for bit in bits: … … 2450 2448 2451 2449 for quantity in ['elevation']+domain.quantities_to_be_stored: 2452 bits.append(' quantities["%s"].get_integral()'%quantity)2453 bits.append('get_quantity("%s") '%quantity)2450 bits.append('get_quantity("%s").get_integral()' %quantity) 2451 bits.append('get_quantity("%s").get_values()' %quantity) 2454 2452 2455 2453 for bit in bits: … … 2457 2455 assert allclose(eval('domain.'+bit),eval('domain2.'+bit)) 2458 2456 2459 assert max(max(domain2.get_quantity('xmomentum') ))==filler2460 assert min(min(domain2.get_quantity('xmomentum') ))==filler2461 assert max(max(domain2.get_quantity('ymomentum') ))==filler2462 assert min(min(domain2.get_quantity('ymomentum') ))==filler2457 assert max(max(domain2.get_quantity('xmomentum').get_values()))==filler 2458 assert min(min(domain2.get_quantity('xmomentum').get_values()))==filler 2459 assert max(max(domain2.get_quantity('ymomentum').get_values()))==filler 2460 assert min(min(domain2.get_quantity('ymomentum').get_values()))==filler 2463 2461 2464 2462 … … 2526 2524 elevation = domain.quantities['elevation'].vertex_values 2527 2525 domain.set_quantity('stage', elevation + h) 2528 #elevation = domain.get_quantity('elevation') 2529 #domain.set_quantity('stage', elevation + h) 2526 2530 2527 2531 2528 domain.check_integrity() … … 2559 2556 for quantity in ['elevation']+domain.quantities_to_be_stored: 2560 2557 bits.append('quantities["%s"].get_integral()'%quantity) 2561 #bits.append('get_quantity("%s")'%quantity) 2558 2562 2559 2563 2560 for bit in bits: … … 2616 2613 ################## 2617 2614 2615 print '><><><><>>' 2618 2616 bits = [ 'vertex_coordinates'] 2619 2617 2620 2618 for quantity in ['elevation','xmomentum','ymomentum']:#+domain.quantities_to_be_stored: 2621 2619 #bits.append('quantities["%s"].get_integral()'%quantity) 2622 bits.append('get_quantity("%s") '%quantity)2620 bits.append('get_quantity("%s").get_values()' %quantity) 2623 2621 2624 2622 for bit in bits:
Note: See TracChangeset
for help on using the changeset viewer.