Skip to content

Задание 3: веб-приложение#1

Open
Rud1ge wants to merge 54 commits into
mainfrom
develop3
Open

Задание 3: веб-приложение#1
Rud1ge wants to merge 54 commits into
mainfrom
develop3

Conversation

@Rud1ge

@Rud1ge Rud1ge commented Jul 20, 2026

Copy link
Copy Markdown
Owner

No description provided.

Руди Герман Геннадьевич and others added 30 commits July 17, 2026 17:23
Configure Chrome WebDriver to launch the locally installed Chromium snap.
Open the app URL before clearing storage to avoid SecurityError on about:blank in Firefox.
Update order history URL, password field locators and order number matching for the current UI.
Store refresh token for UI auth, simplify bun drag-and-drop, and harden modal closing.
Ensure logged-in scenarios use both access and refresh tokens from the API fixture.
Replace partial report artifacts with results from the latest test run.
The previous selector targeted orderListReady («Готовы»).
Keep all page elements used in recovery tests described as locators.
Replace list scanning, regex parsing, and callback waits with
direct locators and plain refresh loops.
Руди Герман Геннадьевич added 24 commits July 20, 2026 10:57
Use EC waits and direct assertions instead of helper predicates
and nested wait callbacks.
Drop unused refresh token and replace next() with a plain loop.
Drop per-call timeout overrides and click through WebElement.click().
Replace the sleep loop with ORDER_NUMBER_READY and open the sauces
tab explicitly before adding a sauce.
Share order creation across feed tests and clear cookies only.
Use timeout=5 in wait signatures and return real is_displayed checks.
Use Selenium ActionChains with move_to_element so ingredients outside
the viewport are added to the basket without custom HTML5 event script.
Use default timeout=3 for shared waits and WebDriverWait(..., 10)
inline for slow order/feed checks, matching the Sprint_6 pattern.
Extract browser creation into a Factory so tests pick the driver by name, as in the cross-browser cheat sheet.
Wire the driver fixture to the factory and reset cookies plus localStorage so Firefox does not keep a stuck auth/loading state.
Wait for the loading overlay before clicks, refresh if it hangs, and dispatch HTML5 drag events via JS so ingredient DnD works in Firefox.
Counters update on the open feed page once the new order shows under «В работе», so reopening the page is unnecessary and flaky.
Refresh Allure artifacts after a full green Chrome and Firefox run.
Without move_to_element, off-screen ingredients (e.g. sauces) never land in the basket, so Chrome counter assertions fail.
Use scope="class" on the parametrized driver fixture so Chrome/Firefox sessions are reused within each test class.
Refresh allure_results after the full suite run with Chrome green.
feed_page.go_to_constructor()

assert FEED_URL not in driver.current_url
assert driver.current_url.startswith(BASE_URL)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Нужно поправить: в подходе РОМ мы не обращаемся напрямую в драйвер (как тут driver.current_url): всё оборачиваем в методы пейджа

@klushcheva

Copy link
Copy Markdown

✅ Сильные стороны:

  • Код запускается без ошибок
  • Подход Page Object Model соблюден
  • Написаны необходимые тесты

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants