fix delete thread test

This commit is contained in:
hlaaftana 2020-05-10 19:15:02 +03:00 • committed by GitHub
commit 2987955e8a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -42,7 +42,13 @@ proc userTests(session: Session, baseUrl: string) =
test "can delete thread": test "can delete thread":
with session: with session:
click userTitleStr, LinkTextSelector # create thread to be deleted
click "#new-thread-btn"
sendKeys "#thread-title", "To be deleted"
sendKeys "#reply-textarea", "This thread is to be deleted"
click "#create-thread-btn"
click ".post-buttons .delete-button" click ".post-buttons .delete-button"
@ -50,7 +56,7 @@ proc userTests(session: Session, baseUrl: string) =
click "#delete-modal .delete-btn" click "#delete-modal .delete-btn"
# Make sure the forum post is gone # Make sure the forum post is gone
checkIsNone userTitleStr, LinkTextSelector checkIsNone "To be deleted", LinkTextSelector
session.logout() session.logout()