Skip to content

Commit 2b84777

Browse files
committed
Update the docs
1 parent fdeafdd commit 2b84777

File tree

3 files changed

+29
-12
lines changed

3 files changed

+29
-12
lines changed

docs/img/sb_logo_7.png

-12.9 KB
Loading

help_docs/method_summary.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ For backwards compatibility, older versions of method names have remained to kee
99
```python
1010
self.open(url)
1111
# Duplicates: self.open_url(url), self.get(url)
12-
# self.visit(url), self.goto(url), self.go_to(url)
12+
# self.visit(url), visit_url(url), self.goto(url), self.go_to(url)
1313

1414
self.click(selector, by=By.CSS_SELECTOR, timeout=None, delay=0)
1515

@@ -29,8 +29,8 @@ self.add_text(selector, text, by=By.CSS_SELECTOR, timeout=None)
2929

3030
self.submit(selector, by=By.CSS_SELECTOR)
3131

32-
self.refresh()
33-
# Duplicates: self.refresh_page()
32+
self.refresh_page()
33+
# Duplicates: self.refresh(), self.reload(), self.reload_page()
3434

3535
self.get_current_url()
3636

@@ -62,8 +62,8 @@ self.get_link_attribute(link_text, attribute, hard_fail=True)
6262

6363
self.get_partial_link_text_attribute(link_text, attribute, hard_fail=True)
6464

65-
self.click_link(link_text, timeout=None)
66-
# Duplicates: self.click_link_text(link_text, timeout=None)
65+
self.click_link_text(link_text, timeout=None)
66+
# Duplicates: self.click_link(link_text, timeout=None)
6767

6868
self.click_partial_link_text(partial_link_text, timeout=None)
6969

help_docs/mobile_testing.md

Lines changed: 24 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,30 @@
1-
[<img src="https://cdn2.hubspot.net/hubfs/100006/images/SeleniumBaseText_F.png" title="SeleniumBase" align="center" width="290">](https://github.com/seleniumbase/SeleniumBase/blob/master/README.md)
1+
<p align="center"><a href="https://github.com/seleniumbase/SeleniumBase/blob/master/README.md"><img src="https://cdn2.hubspot.net/hubfs/100006/images/SeleniumBaseText_F.png" alt="SeleniumBase" title="SeleniumBase" width="290" /></a></p>
2+
23
<h2><img src="https://seleniumbase.io/img/sb_icon.png" title="SeleniumBase" width="30" /> Mobile Testing</h2>
34

4-
Use ``--mobile`` to run your SeleniumBase tests using Chrome's (or Edge's) mobile device emulator with default values for device metrics (CSS Width, CSS Height, Pixel-Ratio) and user agent.
5+
Use ``--mobile`` to run your SeleniumBase tests using Chromium's mobile device emulator with default values for device metrics (CSS Width, CSS Height, Pixel-Ratio) and user agent.
6+
7+
To configure the mobile device metrics, use:
8+
```bash
9+
--metrics="CSS_Width,CSS_Height,Pixel_Ratio"
10+
```
11+
12+
To configure the user agent, use:
13+
```bash
14+
--agent="USER-AGENT-STRING"
15+
```
516

6-
To configure the mobile device metrics, use ``--metrics="CSS_Width,CSS_Height,Pixel_Ratio"``. To configure the user agent, use ``--agent="USER-AGENT-STRING"``.
17+
To find real values for device metrics, see:
18+
* [Device Metrics List](https://gist.github.com/sidferreira/3f5fad525e99b395d8bd882ee0fd9d00)
719

8-
To find real values for device metrics, [see this GitHub Gist](https://gist.github.com/sidferreira/3f5fad525e99b395d8bd882ee0fd9d00). For a list of available user agent strings, [check out this page](https://developers.whatismybrowser.com/useragents/explore/).
20+
For a list of available user agent strings, see:
21+
* [User Agent Strings List](https://developers.whatismybrowser.com/useragents/explore/)
922

1023
--------
1124

12-
Here's an example of running a mobile test (See https://github.com/seleniumbase/SeleniumBase/blob/master/examples/test_skype_site.py):
25+
Here's an example of running a mobile test:
26+
27+
* [SeleniumBase/examples/test_skype_site.py](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/test_skype_site.py)
1328

1429
```bash
1530
pytest test_skype_site.py --mobile
@@ -18,7 +33,7 @@ pytest test_skype_site.py --mobile
1833

1934
--------
2035

21-
Here's another example of running a mobile test (https://github.com/seleniumbase/SeleniumBase/blob/master/examples/test_swag_labs.py), which demonstrates using ``--metrics`` and ``--agent`` with ``--mobile``:
36+
Here's another example of running a mobile test ([SeleniumBase/examples/test_swag_labs.py](https://github.com/seleniumbase/SeleniumBase/blob/master/examples/test_swag_labs.py)), which demonstrates using ``--metrics`` and ``--agent`` with ``--mobile``:
2237

2338
```bash
2439
# Run tests using Chrome's mobile device emulator (default settings)
@@ -34,4 +49,6 @@ pytest test_swag_labs.py --mobile --agent="Mozilla/5.0 (Linux; Android 9; Pixel
3449

3550
--------
3651

37-
If you're new to SeleniumBase, read https://github.com/seleniumbase/SeleniumBase to help you get started.
52+
<p align="center"><div align="center"><a href="https://seleniumbase.io">
53+
<img src="https://img.shields.io/badge/docs-%20📓📖📚-11BBDD.svg" alt="SeleniumBase.io Docs" />
54+
</a> <a href="https://github.com/seleniumbase/SeleniumBase"><img src="https://img.shields.io/badge/✅%20💛%20View%20Code-on%20GitHub%20🌎%20🚀-02A79E.svg" alt="SeleniumBase.io Docs" /></a></div></p>

0 commit comments

Comments
 (0)