Articles categorized as Test Automation

Testing iFrames using Playwright

Automated testing has become an integral part of web application development. However, testing in Safari, Apple's web browser, presents unique challenges due to the browser's strict Same-Origin Policy (SOP), especially when dealing with iframes. In this article, we'll explore known issues related to Safari's SOP, discuss workarounds, and demonstrate how Playwright, a popular automation testing framework, supports automated testing in this context.

Relative Import vs. Absolute Import with Pytest: Best Practices

In Python development with pytest, choosing between relative and absolute imports and deciding whether to execute tests as a script or a module are crucial decisions that impact code organization, readability, and test execution. Relative imports offer clarity within packages, while absolute imports provide explicitness and are favored for larger projects. Running tests as a script allows for quick ad-hoc testing, while module execution ensures consistency in automated CI/CD pipelines. By understanding the best practices and common pitfalls associated with each approach, developers can effectively navigate these choices to maintain clean, reliable, and maintainable codebases.