Hi - i am currently building out some tests for an app i have built, i ahve included st.pills and st.segmented controls in my app, but i cant seem to find a apptest element to allow me to control these elements in my test - am i missing something or is this yet to be developed?
Hey Toby, thanks for your question and welcome to the Streamlit community! You’re not missing anything—currently, the AppTest framework does not provide direct element classes or attributes for st.pills or st.segmented_control. These elements are not yet natively supported for programmatic interaction or value setting in AppTest, so you can’t control them in your tests like you can with buttons, sliders, or selectboxes.
If you need to test logic related to these widgets, you might consider isolating the underlying logic in separate functions and testing those directly, or using browser automation tools like Playwright or Selenium for full end-to-end UI testing. Keep an eye on the official documentation and AppTest API reference for updates, as new widget support is added regularly. If you have a minimum reproducible example, feel free to share it so others can chime in with workarounds or suggestions!