Skip to content

Commit

Permalink
Fixed the intermittent test in #3035. (#3037)
Browse files Browse the repository at this point in the history
* Fixed the intermittent test in #3035.

The problem was that iris.util.format_array was stateful (via np.set_printoptions).

* Fix stateful tests (#26)
  • Loading branch information
pelson authored and bjlittle committed Jun 1, 2018
1 parent 243bb31 commit 0ea1b5d
Show file tree
Hide file tree
Showing 34 changed files with 6,683 additions and 6,966 deletions.
304 changes: 152 additions & 152 deletions lib/iris/tests/results/FF/ffheader.txt

Large diffs are not rendered by default.

240 changes: 114 additions & 126 deletions lib/iris/tests/results/PP/extra_char_data.pp.txt

Large diffs are not rendered by default.

240 changes: 114 additions & 126 deletions lib/iris/tests/results/PP/extra_char_data.w_data_loaded.pp.txt

Large diffs are not rendered by default.

545 changes: 271 additions & 274 deletions lib/iris/tests/results/PP/extra_data_time_series.pp.txt

Large diffs are not rendered by default.

10,505 changes: 5,125 additions & 5,380 deletions lib/iris/tests/results/PP/extra_x_data.pp.txt

Large diffs are not rendered by default.

22 changes: 11 additions & 11 deletions lib/iris/tests/results/PP/global_test.pp.txt
Original file line number Diff line number Diff line change
Expand Up @@ -45,17 +45,17 @@
bplat: 90.0
bplon: 0.0
bgor: 0.0
bzy: 92.5
bdy: -2.5
bzx: -3.75
bdx: 3.75
bzy: 92.499985
bdy: -2.499999
bzx: -3.749999
bdx: 3.749999
bmdi: -1e+30
bmks: 1.0
data: [[ 254.644 254.644 254.644 ..., 254.644 254.644 254.644 ]
[ 254.97499 254.96767 254.98082 ..., 254.98776 255.03467 254.99721]
[ 255.99585 256.30835 256.55875 ..., 256.11685 255.95605 255.83556]
...,
[ 254.57333 253.86855 252.90517 ..., 255.29681 255.3879 255.14859]
[ 252.33691 252.08926 251.85536 ..., 252.59863 252.67467 252.5896 ]
[ 248.74585 248.74585 248.74585 ..., 248.74585 248.74585 248.74585]]
data: [[254.644 254.644 254.644 ... 254.644 254.644 254.644 ]
[254.97499 254.96767 254.98082 ... 254.98776 255.03467 254.99721]
[255.99585 256.30835 256.55875 ... 256.11685 255.95605 255.83556]
...
[254.57333 253.86855 252.90517 ... 255.29681 255.3879 255.14859]
[252.33691 252.08926 251.85536 ... 252.59863 252.67467 252.5896 ]
[248.74585 248.74585 248.74585 ... 248.74585 248.74585 248.74585]]
]
64 changes: 32 additions & 32 deletions lib/iris/tests/results/PP/nae_unpacked.pp.txt
Original file line number Diff line number Diff line change
Expand Up @@ -49,15 +49,15 @@
bdy: 0.11
bzx: 326.11
bdx: 0.11
bmdi: -1.07374e+09
bmdi: -1073741800.0
bmks: 1.0
data: [[ 388.78125 389.46875 384.0625 ..., 318.1875 310.84375 307.79688]
[ 388.09375 381.375 374.28125 ..., 310.28125 305.59375 300.53125]
[ 382.34375 373.67188 371.17188 ..., 297.04688 293.10938 288.48438]
...,
[ 0. 0. 0. ..., 0. 0. 0. ]
[ 0. 0. 0. ..., 0. 0. 0. ]
[ 0. 0. 0. ..., 0. 0. 0. ]]
data: [[388.78125 389.46875 384.0625 ... 318.1875 310.84375 307.79688]
[388.09375 381.375 374.28125 ... 310.28125 305.59375 300.53125]
[382.34375 373.67188 371.17188 ... 297.04688 293.10938 288.48438]
...
[ 0. 0. 0. ... 0. 0. 0. ]
[ 0. 0. 0. ... 0. 0. 0. ]
[ 0. 0. 0. ... 0. 0. 0. ]]
, PP Field
lbyr: 2010
lbmon: 1
Expand Down Expand Up @@ -109,15 +109,15 @@
bdy: 0.11
bzx: 326.11
bdx: 0.11
bmdi: -1.07374e+09
bmdi: -1073741800.0
bmks: 1.0
data: [[ 226.07812 226.51562 231.92188 ..., 244.79688 251.34375 254.57812]
[ 225.625 233.29688 241.17188 ..., 250.42188 254.65625 259.45312]
[ 230.04688 239.89062 242.84375 ..., 260.92188 264.59375 269.09375]
...,
[ 0. 0. 0. ..., 0. 0. 0. ]
[ 0. 0. 0. ..., 0. 0. 0. ]
[ 0. 0. 0. ..., 0. 0. 0. ]]
data: [[226.07812 226.51562 231.92188 ... 244.79688 251.34375 254.57812]
[225.625 233.29688 241.17188 ... 250.42188 254.65625 259.45312]
[230.04688 239.89062 242.84375 ... 260.92188 264.59375 269.09375]
...
[ 0. 0. 0. ... 0. 0. 0. ]
[ 0. 0. 0. ... 0. 0. 0. ]
[ 0. 0. 0. ... 0. 0. 0. ]]
, PP Field
lbyr: 2010
lbmon: 1
Expand Down Expand Up @@ -169,15 +169,15 @@
bdy: 0.11
bzx: 326.11
bdx: 0.11
bmdi: -1.07374e+09
bmdi: -1073741800.0
bmks: 1.0
data: [[ 412.875 413.5625 407.875 ..., 522.9531 523.2656 524.4531 ]
[ 412.1875 405.07812 397.57812 ..., 521.9531 522.4219 523.25 ]
[ 406.1875 397.01562 394.35938 ..., 521.5156 522.0469 522.875 ]
...,
[ 0. 0. 0. ..., 0. 0. 0. ]
[ 0. 0. 0. ..., 0. 0. 0. ]
[ 0. 0. 0. ..., 0. 0. 0. ]]
data: [[412.875 413.5625 407.875 ... 522.9531 523.2656 524.4531 ]
[412.1875 405.07812 397.57812 ... 521.9531 522.4219 523.25 ]
[406.1875 397.01562 394.35938 ... 521.5156 522.0469 522.875 ]
...
[ 0. 0. 0. ... 0. 0. 0. ]
[ 0. 0. 0. ... 0. 0. 0. ]
[ 0. 0. 0. ... 0. 0. 0. ]]
, PP Field
lbyr: 2010
lbmon: 1
Expand Down Expand Up @@ -229,19 +229,19 @@
bdy: 0.11
bzx: 326.11
bdx: 0.11
bmdi: -1.07374e+09
bmdi: -1073741800.0
bmks: 1.0
data: [[ -61.265625 -61.3125 -60.4375 ..., -198.17188 -193.73438
data: [[ -61.265625 -61.3125 -60.4375 ... -198.17188 -193.73438
-189.3125 ]
[ -61.234375 -60.0625 -58.6875 ..., -197.51562 -193.70312
[ -61.234375 -60.0625 -58.6875 ... -197.51562 -193.70312
-189.9375 ]
[ -60.390625 -59.03125 -58.640625 ..., -193.48438 -190.14062
[ -60.390625 -59.03125 -58.640625 ... -193.48438 -190.14062
-186.78125 ]
...,
[ -73.28125 -19.171875 -3.03125 ..., -19.03125 -16.65625
...
[ -73.28125 -19.171875 -3.03125 ... -19.03125 -16.65625
-48.828125]
[ -48.1875 1.265625 -17.765625 ..., -17.21875 -41.3125
[ -48.1875 1.265625 -17.765625 ... -17.21875 -41.3125
-64.65625 ]
[ -72.578125 -46.671875 -68.734375 ..., -49.15625 -66.71875
[ -72.578125 -46.671875 -68.734375 ... -49.15625 -66.71875
-65.6875 ]]
]
Loading

0 comments on commit 0ea1b5d

Please sign in to comment.