(dash_duo)
| 239 | |
| 240 | |
| 241 | def test_rdps006_move_on_page(dash_duo): |
| 242 | app = Dash(__name__) |
| 243 | app.layout = html.Div( |
| 244 | [html.Button("move table", id="move-table"), html.Div(id="container")] |
| 245 | ) |
| 246 | |
| 247 | @app.callback(Output("container", "children"), [Input("move-table", "n_clicks")]) |
| 248 | def move_table(n): |
| 249 | children = [html.Div("div 0", id="div0"), simple_table()] |
| 250 | for i in range(1, (n or 0) + 1): |
| 251 | children = [ |
| 252 | html.Div("div {}".format(i), id="div{}".format(i)), |
| 253 | html.Div(children), |
| 254 | ] |
| 255 | return children |
| 256 | |
| 257 | def find_last_div(n): |
| 258 | dash_duo.wait_for_text_to_equal("#div{}".format(n), "div {}".format(n)) |
| 259 | assert len(dash_duo.find_elements("#div{}".format(n + 1))) == 0 |
| 260 | |
| 261 | dash_duo.start_server(app) |
| 262 | find_last_div(0) |
| 263 | check_table_names(dash_duo, ["a", "b"]) |
| 264 | |
| 265 | rename_and_hide(dash_duo) |
| 266 | check_table_names(dash_duo, [NEW_NAME]) |
| 267 | |
| 268 | for i in range(1, 5): |
| 269 | dash_duo.find_element("#move-table").click() |
| 270 | find_last_div(i) |
| 271 | check_table_names(dash_duo, [NEW_NAME]) |
| 272 | |
| 273 | |
| 274 | def test_rdps007_one_prop_changed(dash_duo): |
nothing calls this directly
no test coverage detected
searching dependent graphs…