File tree Expand file tree Collapse file tree 4 files changed +27
-3
lines changed Expand file tree Collapse file tree 4 files changed +27
-3
lines changed Original file line number Diff line number Diff line change @@ -22,6 +22,7 @@ def test_swag_labs(self):
22
22
self .click ("input#continue" )
23
23
self .assert_text ("CHECKOUT: OVERVIEW" )
24
24
self .assert_text ("Backpack" , "div.cart_item" )
25
+ self .assert_text ("29.99" , "div.inventory_item_price" )
25
26
self .click ("button#finish" )
26
27
self .assert_exact_text ("THANK YOU FOR YOUR ORDER" , "h2" )
27
28
self .assert_element ('img[alt="Pony Express"]' )
Original file line number Diff line number Diff line change
1
+ """Call a file with "python" instead of using "pytest" directly.
2
+ To run, use: "python raw_file_call.py".
3
+ Works by using pytest.main([__file__])."""
4
+ from seleniumbase import BaseCase
5
+
6
+ if __name__ == "__main__" :
7
+ from pytest import main
8
+
9
+ main ([__file__ ])
10
+
11
+
12
+ class TinyMceTest (BaseCase ):
13
+ def test_tinymce (self ):
14
+ self .open ("https://seleniumbase.io/tinymce/" )
15
+ self .wait_for_element ("div.mce-container-body" )
16
+ self .click ('span:contains("File")' )
17
+ self .click ('span:contains("New document")' )
18
+ self .click ('span:contains("Paragraph")' )
19
+ self .click ('span:contains("Heading 1")' )
20
+ with self .frame_switch ("iframe" ):
21
+ self .add_text ("#tinymce" , "SeleniumBase!" )
22
+ self .highlight ("#tinymce" )
23
+ self .switch_to_default_content ()
24
+ self .post_message ("SeleniumBase is the best!" )
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ def test_tinymce(self):
14
14
self .switch_to_default_content ()
15
15
self .click ("button i.mce-i-image" )
16
16
self .type ('input[aria-label="Width"].mce-textbox' , "300" )
17
- image_url = "https://seleniumbase.io/img/sb_logo_10.png"
17
+ image_url = "https://seleniumbase.github. io/img/sb_logo_10.png"
18
18
self .type ("input.mce-textbox" , image_url + "\n " )
19
19
self .switch_to_frame ("iframe" )
20
20
self .click ("h2" )
Original file line number Diff line number Diff line change 1
- """ Testing the self.choose_file() and self.assert_attribute() methods. """
2
-
1
+ """Testing the self.choose_file() and self.assert_attribute() methods."""
3
2
import os
4
3
from seleniumbase import BaseCase
5
4
You can’t perform that action at this time.
0 commit comments