Skip to content

Commit 3cc765a

Browse files
committed
Update the HTML Inspector
1 parent e144cec commit 3cc765a

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

help_docs/html_inspector.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ pytest test_inspect_html.py
2828
⚠️ 'property' is not a valid attribute of the <meta> element.
2929
⚠️ Do not use <div> or <span> elements without any attributes.
3030
⚠️ 'srcset' is not a valid attribute of the <img> element.
31-
⚠️ The 'border' attribute is no longer valid on the <img> element and should not be used.
32-
⚠️ The <center> element is obsolete and should not be used.
31+
⚠️ The 'border' attribute is no longer valid on the <img> element.
32+
⚠️ The <center> element is obsolete.
3333
⚠️ The id 'comicLinks' appears more than once in the document.
3434
* (See the Console output for details!)
3535
```

seleniumbase/fixtures/base_case.py

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7127,9 +7127,15 @@ def inspect_html(self):
71277127
if "0:6053 " in message:
71287128
message = message.split("0:6053")[1]
71297129
message = message.replace("\\u003C", "<")
7130+
message = message.replace(" and should not be used", "")
71307131
if message.startswith(' "') and message.count('"') == 2:
71317132
message = message.split('"')[1]
7132-
message = "⚠️ " + message
7133+
if "but not found in any stylesheet" in message:
7134+
continue
7135+
if not is_windows:
7136+
message = "⚠️ " + message
7137+
else:
7138+
message = "!-> " + message # CMD prompt compatibility
71337139
if messenger_library not in message:
71347140
if message not in results:
71357141
results.append(message)

0 commit comments

Comments
 (0)