Skip to content

Commit

Permalink
Migrate st balloons to playwright (streamlit#8678)
Browse files Browse the repository at this point in the history
## Describe your changes
- title, does it by checking the data-testid exists
## GitHub Issue Link (if applicable)

## Testing Plan

- Explanation of why no additional tests are needed
- Unit Tests (JS and/or Python)
- E2E Tests
- Any manual testing needed?

---

**Contribution License Agreement**

By submitting this pull request you agree that all contributions to this
project are made under the Apache 2.0 license.
  • Loading branch information
willhuang1997 authored May 15, 2024
1 parent dc3ef00 commit 199e15e
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 34 deletions.
34 changes: 0 additions & 34 deletions e2e/specs/st_balloons.spec.js

This file was deleted.

File renamed without changes.
19 changes: 19 additions & 0 deletions e2e_playwright/st_balloons_test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Copyright (c) Streamlit Inc. (2018-2022) Snowflake Inc. (2022-2024)
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

from playwright.sync_api import Page, expect


def test_balloons_are_present_on_page(app: Page):
expect(app.get_by_test_id("balloons")).to_have_count(1)

0 comments on commit 199e15e

Please sign in to comment.