# Source: https://docs.streamlit.io/develop/api-reference/app-testing/st.testing.v1.apptest

# st.testing.v1.AppTest

The AppTest class simulates Streamlit apps in automated tests and provides methods to manipulate and inspect app contents programmatically.

## Methods

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or key lookup.

### run

Run the script from the current state.

This is equivalent to manually rerunning the app or the rerun that occurs upon user interaction. AppTest.run() must be manually called after updating a widget value or switching pages as script reruns do not occur automatically as they do for live-running Streamlit apps.

### switch_page

Switch to another page of the app.

This method does not automatically rerun the app. Use a follow-up call to AppTest.run() to obtain the elements on the selected page.

### get

Get elements or widgets of the specified type.

This method returns the collection of all elements or widgets of the specified type on the current page. Retrieve a specific element by using its index (order on page) or