Skip to content

Soft Assertions #1847

Answered by mdmintz
wellfour asked this question in Q&A
Discussion options

You must be logged in to vote

Hello, and welcome. Yes, SeleniumBase deferred asserts allow you to make multiple assertions on the same page without failing the test after the first failed assert. Instead, you can choose when to process those assertions by calling: self.process_deferred_asserts().

Methods:

self.deferred_assert_element(selector, by="css selector", timeout=None, fs=False)
# Duplicates:
# self.delayed_assert_element(selector, by="css selector", timeout=None, fs=False)

self.deferred_assert_element_present(selector, by="css selector", timeout=None, fs=False)
# Duplicates:
# self.delayed_assert_element_present(selector, by="css selector", timeout=None, fs=False)

self.deferred_assert_text(text, selector="html"

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by mdmintz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants