- Timestamp:
- Nov 11, 2010, 11:55:52 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/anuga_core/source/anuga/shallow_water/test_forcing_terms.py
r7814 r8068 887 887 domain.forcing_terms.append(R) 888 888 889 # This will test that time used in the forcing function takes 890 # startime into account. 891 domain.starttime = 5.0 892 893 domain.time = 7. 889 # This will test that time is set to starttime in set_starttime 890 domain.set_starttime(5.0) 894 891 895 892 domain.compute_forcing_terms() … … 898 895 (3*domain.get_time() + 7)/1000) 899 896 assert num.allclose(domain.quantities['stage'].explicit_update[1], 900 (3*(domain.time + domain.starttime) + 7)/1000) 901 902 # Using internal time her should fail 903 assert not num.allclose(domain.quantities['stage'].explicit_update[1], 904 (3*domain.time + 7)/1000) 897 (3*domain.get_starttime() + 7)/1000) 905 898 906 899 assert num.allclose(domain.quantities['stage'].explicit_update[0], 0) … … 953 946 domain.forcing_terms.append(R) 954 947 955 # This will test that time used in the forcing function takes 956 # startime into account. 957 domain.starttime = 5.0 958 959 domain.time = 7. 948 # This will test that time is set to starttime in set_starttime 949 domain.set_starttime(5.0) 960 950 961 951 domain.compute_forcing_terms() … … 964 954 (3*domain.get_time() + 7)/1000) 965 955 assert num.allclose(domain.quantities['stage'].explicit_update[1], 966 (3*(domain.time + domain.starttime) + 7)/1000) 967 968 # Using internal time her should fail 969 assert not num.allclose(domain.quantities['stage'].explicit_update[1], 970 (3*domain.time + 7)/1000) 956 (3*domain.get_starttime() + 7)/1000) 957 971 958 972 959 assert num.allclose(domain.quantities['stage'].explicit_update[0], 0)
Note: See TracChangeset
for help on using the changeset viewer.