(fig_test, fig_ref, pd)
| 2275 | |
| 2276 | @check_figures_equal() |
| 2277 | def test_grouped_bar_dataframe(fig_test, fig_ref, pd): |
| 2278 | categories = ['A', 'B'] |
| 2279 | labels = ['data1', 'data2', 'data3'] |
| 2280 | df = pd.DataFrame([[1, 2, 3], [1.2, 2.4, 3.6]], |
| 2281 | index=categories, columns=labels) |
| 2282 | |
| 2283 | ax = fig_test.subplots() |
| 2284 | ax.grouped_bar(df) |
| 2285 | ax.legend() |
| 2286 | |
| 2287 | ax = fig_ref.subplots() |
| 2288 | list_of_datasets = [df[col].to_numpy() for col in df.columns] |
| 2289 | ax.grouped_bar(list_of_datasets, tick_labels=categories, labels=labels) |
| 2290 | ax.legend() |
| 2291 | |
| 2292 | |
| 2293 | def test_grouped_bar_return_value(): |
nothing calls this directly
no test coverage detected
searching dependent graphs…