Curated interview practice questions with answers. These are practice scenarios, not a verified list of past interview questions.
About Birlasoft hiring for Playwright Testing roles
Birlasoft is an Indian IT services company and part of the CK Birla Group. It focuses on enterprise solutions such as Oracle, SAP and Microsoft applications, along with cloud, data and testing services for manufacturing, life sciences and energy clients. In India it hires for software engineers, ERP consultants, test engineers and data analysts.
For Playwright Testing roles, this Birlasoft practice set focuses most on Playwright Core (7), API Testing (7), JavaScript and TypeScript (6), Debugging and Trace Viewer (4). It has 20 easy, 18 medium, 2 hard questions, so you can start easy and work up to the harder ones.
Company type
IT services
Headquarters
Pune, India
Main India offices
Pune, Noida, Bengaluru, Chennai
Birlasoft Playwright Testing interview process
Online assessment (aptitude + reasoning)
Technical MCQs
Technical interview
HR round
Typical pattern based on public candidate experiences. Rounds vary by role, team and year.
Solved for BirlasoftStart practicing
3 QUESTIONS FREESign up to unlock the full question bank and track your progress.Unlock every question and answer, then continue practising company-wise and package-wise.
Count the items, then scroll the last item into view with lastItem.scrollIntoViewIfNeeded() or page.mouse.wheel. Assert with expect(items).toHaveCount greater than before, for example using expect.poll on items.count(). Repeat until an end-of-list message appears. Also check no duplicates appear and that a loading indicator shows while fetching.
04
How would you type the response of an API call in TypeScript?
Define an interface for the payload, cast or validate the parsed JSON to it (for example with zod), and use that type in assertions to catch shape changes.
The HTML reporter creates a playwright-report folder with every test, its steps, errors, attachments, screenshots and trace links. Open it with npx playwright show-report. You can filter by status, project and tags. In CI, upload the folder as an artifact so anyone can download and open it, and the report opens automatically locally when tests fail.
07
What is the difference between ES modules and CommonJS?
ES modules use import and export and are the modern standard, loaded statically. CommonJS uses require and module.exports and is the older Node.js style. Playwright supports both, and TypeScript test projects usually write import syntax. Mixing them causes errors such as require is not defined, so set type in package.json and tsconfig consistently.
page is a fresh tab for each test. context is the isolated browser context that owns the page, with its own cookies and storage. browser is the shared browser instance for the worker. request is an APIRequestContext for HTTP calls. You ask for them by name in the test function, and Playwright creates and cleans them up automatically.
An animation captured at a slightly different frame produces a different image, so the test fails even though nothing is broken. With animations: 'disabled', which is the default for toHaveScreenshot, Playwright fast-forwards finite animations to their end state and resets infinite ones to their start. This gives the same picture every run. Transitions triggered by hover or focus are handled the same way.
getByRole finds elements by their ARIA role and accessible name, the same way screen readers and users see the page. For example getByRole('button', { name: 'Save' }) keeps working when CSS classes or DOM structure change. It also pushes the team towards accessible markup. The trade-off is that badly built components without proper roles may need a test id instead.
18
How do you select an option from a native select dropdown?
toBeAttached only checks that the element exists in the DOM. toBeVisible also needs it to have a non-empty bounding box and no visibility:hidden style. A hidden modal can be attached but not visible. Use toBeVisible for anything a user should see, and toBeAttached for hidden inputs or elements whose presence matters more than appearance.
22
Why are component tests usually faster than end-to-end tests?
They skip the expensive parts: no full app start, no backend calls, no login and no navigation through several pages. Playwright builds the component bundle once and each test simply mounts into an already loaded page. A typical component test finishes in well under a second, so hundreds can run in a pull request check, while end-to-end flows take several seconds each.
beforeAll runs once before the tests in its file or describe block, and afterAll runs once after them. In Playwright they run once per worker, so if tests are spread over workers they can run more than once. They suit cheap shared setup. They cannot use test-scoped fixtures like page, so open your own page from the browser fixture if needed.
25
What is UI mode and how is it different from --debug?
UI mode, opened with npx playwright test --ui, is a dashboard to run, filter and watch tests, with a trace-like timeline for each one and a watch mode that reruns on file changes. --debug opens the Inspector to step through a single run live. Use UI mode for daily development and --debug for stepping through a specific action.
// waits until exactly 5 data rows are rendered
const rows = page.getByRole('table').getByRole('row');
await expect(rows).toHaveCount(6); // 1 header + 5 rows
// avoid: expect(await rows.count()).toBe(6)
// that reads once and does not retry
Most often an action was not awaited, so the test finished and Playwright closed the page while the action was still running. Other causes are a test timeout closing the page, the code closing the page or context itself, or the browser crashing. Check the stack for the missing await, look at whether a timeout happened first, and turn on the lint rule for floating promises.
29
What happens before and after await use() in a fixture?
Code before await use(value) is setup and runs before the test. use hands the value to the test and waits while the test runs. Code after it is teardown and runs when the test finishes, even if it failed. This keeps setup and cleanup for one resource in one place, which is cleaner than a separate beforeEach and afterEach pair.
30
What is the difference between path parameters and query parameters?
Path parameters identify a specific resource and are part of the URL path, like /users/42. Query parameters filter, sort or paginate and follow a question mark, like /users?city=Delhi&page=2. In tests, check invalid path ids return 404, and that each query parameter changes results correctly, including invalid and missing values.
31
How would you design a visual testing strategy for a large web application?
Snapshot stable, high-value screens and shared components, not every page. Render baselines only in a pinned Docker image, mask or mock dynamic data, and disable animations. Keep visual tests in their own project or tag so they can run on pull requests touching UI code. Define owners for baseline reviews and keep thresholds strict in config. Combine with functional assertions, because pictures alone do not tell you why something broke.
32
Show a config with a setup project and a browser project that reuses its login.
Worker fixtures and beforeAll run first for the worker. For each test, the test fixtures it needs are set up, then beforeEach hooks run, then the test body. Afterwards afterEach hooks run, then test fixtures are torn down in reverse order. afterAll and worker fixture teardown run when the worker finishes. Fixtures are lazy, so unused ones never run.
35
How does Playwright compare with Selenium and Cypress?
Playwright supports multiple browsers, tabs, languages and has auto-waiting and tracing; Selenium has the widest ecosystem; Cypress runs in-browser with a great UI but has more limits across tabs.
36
What is the difference between @playwright/test and the playwright package?
@playwright/test is the test runner with fixtures, assertions, parallel workers, retries, reports and config. The playwright package is the automation library alone, used for scripts like scraping or generating PDFs, where you launch browsers yourself. For testing, install @playwright/test. Both share the same browser automation API underneath.
--headed shows the browser window instead of running headless, so you can watch the test. slowMo, set in launchOptions, adds a delay in milliseconds before every action, which makes fast steps visible. Both help when you are writing or debugging a test. Do not leave slowMo on in CI, because it slows every action.
ctViteConfig is an option in the use block of playwright-ct.config.ts that passes extra Vite settings to the component bundle. You need it when the app relies on path aliases, plugins, environment defines or special asset handling that Playwright's default Vite setup does not know about. A typical case is adding resolve.alias so imports like @/components work in tests.
40
Describe a time an API changed without notice and broke your tests.
Situation: dozens of tests failed after a field was renamed from user_name to username. Task: fix quickly and prevent repeats. Action: I updated the shared types and helper, so the fix touched two files, and proposed schema checks on key endpoints plus a heads-up in release notes. Result: the next breaking change was caught in the pull request.
Tips to crack the Birlasoft Playwright Testing interview
Learn basic ERP concepts such as procure-to-pay and order-to-cash, as many Birlasoft projects involve enterprise applications.
Revise SQL and data basics, since ERP and analytics roles both rely on strong querying skills.
Read about the CK Birla Group and Birlasoft's manufacturing and life sciences client focus.
Keep a one-minute story ready for every project on your CV: problem, your part, tools, result.
Practise the hard questions on this page aloud; Birlasoft interviewers usually ask follow-ups on your first answer.
Frequently asked questions
How many rounds are there in the Birlasoft Playwright Testing interview?
Candidates usually go through 4 stages: Online assessment (aptitude + reasoning); Technical MCQs; Technical interview; HR round. The exact rounds change with the role, team, location and your experience, so confirm the process with the recruiter.
Which topics should I prepare for the Birlasoft Playwright Testing interview?
This practice set leans on Playwright Core (7), API Testing (7), JavaScript and TypeScript (6), Debugging and Trace Viewer (4). Revise those first, then practise explaining one or two of your own projects end to end, because most Birlasoft interviewers ask you to walk through real work.
Are these the exact questions asked at Birlasoft?
No. These are curated practice questions that match the skills and difficulty usually tested in it services interviews like Birlasoft's. They are not a leaked or verified list of past questions.
Where does Birlasoft hire Playwright Testing professionals in India?
Birlasoft has large teams in Pune, Noida, Bengaluru, Chennai. Openings and locations change often, so check the Birlasoft careers page and filter by city and experience.
Playwright Testing questions for similar companies