Smoketest that bar can handle width and height in delta units.
()
| 2164 | |
| 2165 | |
| 2166 | def test_bar_timedelta(): |
| 2167 | """Smoketest that bar can handle width and height in delta units.""" |
| 2168 | fig, ax = plt.subplots() |
| 2169 | ax.bar(datetime.datetime(2018, 1, 1), 1., |
| 2170 | width=datetime.timedelta(hours=3)) |
| 2171 | ax.bar(datetime.datetime(2018, 1, 1), 1., |
| 2172 | xerr=datetime.timedelta(hours=2), |
| 2173 | width=datetime.timedelta(hours=3)) |
| 2174 | fig, ax = plt.subplots() |
| 2175 | ax.barh(datetime.datetime(2018, 1, 1), 1, |
| 2176 | height=datetime.timedelta(hours=3)) |
| 2177 | ax.barh(datetime.datetime(2018, 1, 1), 1, |
| 2178 | height=datetime.timedelta(hours=3), |
| 2179 | yerr=datetime.timedelta(hours=2)) |
| 2180 | fig, ax = plt.subplots() |
| 2181 | ax.barh([datetime.datetime(2018, 1, 1), datetime.datetime(2018, 1, 1)], |
| 2182 | np.array([1, 1.5]), |
| 2183 | height=datetime.timedelta(hours=3)) |
| 2184 | ax.barh([datetime.datetime(2018, 1, 1), datetime.datetime(2018, 1, 1)], |
| 2185 | np.array([1, 1.5]), |
| 2186 | height=[datetime.timedelta(hours=t) for t in [1, 2]]) |
| 2187 | ax.broken_barh([(datetime.datetime(2018, 1, 1), |
| 2188 | datetime.timedelta(hours=1))], |
| 2189 | (10, 20)) |
| 2190 | |
| 2191 | |
| 2192 | def test_bar_datetime_start(): |
nothing calls this directly
no test coverage detected
searching dependent graphs…