Latest / Software Testing with Fexingo: QA, Automation, and Reliable Software Engineering / How Figma Prevented a Catastrophic UI Collapse
Transcript
- Lucas: Look, if you’ve been in software engineering long enough, you know the panic of seeing a red build flag on a Friday afternoon. But there is a different, quieter kind of panic that’s been creeping up in the last eighteen months. It happens when the builds are green, the tests pass, the deployment goes out smoothly, and then three days later, a customer calls saying the checkout button is overlapping the price tag. Luna: Right, because the logic worked. The code executed. But the visual layer collapsed under its own weight. It’s like the plumbing is fine, but the house is sinking. Lucas: Exactly. And I want to talk about why our traditional testing strategies are failing us here, specifically regarding dynamic UI components. Most teams treat the front end as a secondary concern compared to backend logic. They rely heavily on unit tests for functions and integration tests for API endpoints. But the modern web stack has become so complex that checking if a button exists no longer means checking if it looks right or behaves correctly in context. Luna: So we’re testing the skeleton but ignoring the skin. When did this disconnect actually start becoming a problem? Lucas: It accelerated with the rise of atomic design systems and component libraries. Think about a company like Stripe or Shopify. They built massive internal libraries where a single button component might be used ten thousand times across different pages. If you update that one component to fix a spacing issue, you break ten thousand instances unless your testing strategy accounts for visual context. And most don’t. Luna: That sounds terrifying. How do you even test a pixel without manually clicking through every page? Lucas: You can’t click everything. That’s manual testing, and it doesn’t scale. What you need is visual regression testing, but not the naive version that just takes screenshots. I’m talking about semantic visual testing. You have to understand the structure of the DOM alongside the pixels. If a text label moves two pixels to the left, a standard screenshot diff might flag it as a failure. But if a critical error message disappears behind a header, a standard diff might miss it entirely because the overall image similarity is still ninety-nine percent. Luna: So the tool itself is lying to you by giving you a high similarity score while hiding a catastrophic layout shift. Lucas: Precisely. And this brings me to the specific case I want to unpack today. A mid-sized fintech startup, let’s call them FinFlow, had a classic case of this. They were scaling rapidly in Q2 of this year. Their engineering team pushed forty new features in six weeks. Their CI pipeline showed a hundred percent pass rate on all automated tests. Zero flaky tests. Zero failures. Yet, their customer support tickets related to UI glitches spiked by sixty percent month-over-month. Luna: Forty percent increase in UI complaints while the codebase claims perfection? That’s a massive blind spot. Lucas: It was. So they brought in an external audit. What they found was that their test suite was only covering the happy path. They tested that the login button worked when clicked. They didn’t test what happened when the network latency spiked during the render phase. They didn’t test how the component library handled edge cases like extremely long usernames or currency symbols with three decimal places. The tests were brittle in the wrong way. They assumed static data and stable environments. Luna: Which means the tests were passing because they were too simple, not because the product was robust. Is this common in smaller teams? Lucas: Extremely common. In fact, I’d argue it’s the default state for most startups until they hit Series B. The pressure to ship feature velocity overrides the investment in infrastructure. But here is the concrete thing you should take away from this: you need to implement contract testing for your frontend components. Not just for APIs, but for the UI contract itself. Luna: UI contracts? Like, defining what the interface promises to deliver before you write the code? Lucas: Yes. Storybook and similar tools allow you to define states for every component. Loading state, error state, empty state, overflow state. When you update a component, you run the visual regression suite against all these defined states. If the loading spinner overlaps the text in the loading state, the test fails. It’s not about perfect pixels; it’s about functional integrity within defined boundaries. Luna: That makes sense. It shifts the focus from 'does it look like the design file?' to 'does it function correctly in all its possible forms?' Lucas: Exactly. And this requires a cultural shift. Designers and engineers need to agree on these states upfront. Too often, designers hand off static mockups. But real software lives in motion and in error. If you aren’t testing for the error state, you aren’t testing the product. You’re testing the dream version of the product. Luna: I love that distinction. Testing the dream vs testing the reality. So how do you measure if your current tests are catching these issues? Lucas: You look at the ratio of bugs reported in production versus bugs caught in staging. For FinFlow, that ratio was roughly one to fifty. They were missing almost all of them. After implementing semantic visual testing and expanding their component states, that ratio flipped to roughly one to five. They caught more bugs earlier, which is cheaper and faster to fix. Luna: That’s a huge return on investment. But isn’t setting up this level of testing expensive? Does it slow down the dev cycle? Lucas: Initially, yes. It adds time to the build pipeline. Visual diffs are computationally expensive. But the cost of fixing a bug in production is exponentially higher. You have hotfixes, customer communication, potential churn, and reputation damage. Investing in smarter testing early pays for itself within a few quarters. Plus, you reduce the cognitive load on developers who otherwise have to manually verify layouts after every merge. Luna: So it’s not just about quality control; it’s about developer experience and mental bandwidth. Lucas: Absolutely. Developers hate context switching. If they push code and have to wait three hours for a manual QA review, that’s friction. Automated, reliable tests give them immediate feedback. The key is reliability. If your visual tests are flaky, developers will ignore them. You have to tune the sensitivity thresholds carefully. Don’t fail on minor anti-aliasing differences. Fail on layout breaks, color changes in critical alerts, or missing interactive elements. Luna: Right, noise leads to alert fatigue. You want signals, not noise. This feels like a lesson that applies beyond just tech companies. Any product with a user interface faces this. Lucas: It does. Even hardware companies with companion apps face this. The digital touchpoint is increasingly the primary interface for many brands. If that interface is unstable, the brand perception suffers regardless of how good the physical product is. Quality is no longer just a backend metric. It’s a holistic user experience metric. Luna: So for listeners managing teams, the takeaway is to stop treating UI testing as an afterthought. Integrate it into the definition of done. Lucas: Spot on. Define the contract. Test the states. Trust the data, but verify the context. It’s harder work upfront, but it saves you from the quiet panic of Friday afternoons. Luna: And it builds a culture where quality is shared, not siloed in a separate QA department that reviews things at the end. Lucas: Exactly. Quality is everyone’s job, but testing needs to be everyone’s tool. Before we wrap up, I want to mention something important about how we keep this conversation going. We deliberately don't run ads on these shows because we believe the insights should be accessible without interruption. If today's tech conversation gave you something usable, consider supporting that choice directly. The link is buy me a coffee dot com slash fexingo. It helps us keep the lights on and the research deep. Luna: Yeah, we appreciate it. It keeps us focused on the signal rather than chasing clicks. Thanks for keeping us independent. Lucas: Back to the topic. One final thought on implementation. Start small. Pick your most critical user journey, maybe the checkout flow or the login sequence. Build a comprehensive set of component states for those pages. Run visual tests against them. See what breaks. Then expand outward. Don’t try to boil the ocean overnight. Luna: Progress over perfection. Test the parts that matter most first. Lucas: Always. The goal isn’t zero bugs. It’s knowing exactly what you’re shipping and why it works. That confidence is worth more than any perfect test score. Luna: Confidence in the code, clarity in the interface. That’s the new standard for reliable software. Lucas: Let’s see if we can get there. Next week, we’ll look at how data contracts are preventing integration breakdowns in microservices architectures. Luna: Sounds like another essential layer of the invisible infrastructure we rely on daily. Lucas: It really is. Until then, keep your pipelines green and your pixels aligned. Luna: Thanks for listening. We’ll catch you next time.