Solar flares can break websites!
We recently spotted an unusual bug that we believe was caused by a solar flare. In this post we'll document how the issue was identified and how it was resolved.
We recently spotted an unusual bug that we believe was caused by a solar flare. In this post we'll document how the issue was identified and how it was resolved.
TL;DR: Store monetary values in value objects for developer convience whilst also helping you develop reusable code that feels natural to OOP and addresses precision issues.
We heavily use Docker for Mac for the internal development of our products. It allows us to closely replicate the internal, automated testing, user acceptance testing and production platforms. There is just one problem, that I'm sure you've also found... The performance of the file system when using volume mounts.
Recently when writing some tests using a data provider in PHPUnit, I wanted to be able to re-run a specific set, rather than the test with every single set in the data provider. I discovered the filtering options available in PHPUnit were a lot more powerful than I'd first thought.
Recently while debugging some tests that were failing on our build server, but passing locally, we needed to see the state of the Database for the application when a test had failed - using Behat hooks and the Symfony Process component, here's how we did it.
We needed SSL certificates for a multi-tenanted app (single app that loads different configuration based on the tenant that accesses it) that relied on domain based tenant location (done via CNAME as the domains were different per tenant). It also had to be easily configurable so that adding a new tenant didn't require major work to get them up and running.
We've found ourselves needing some higher-level tests for some emails that were being sent recently (via a command that's run regularly from a cron) - here's how we did it!
Recently I discovered the finer controls for whitespace within twig, beyond just the 'spaceless' option.
In a recent project of ours, we needed to conditionally link a CSS file if it existed for a given tenant within a multi-tenant system. We didn't want to have every controller or action have to check for this file and pass the results to Twig. Luckily for us, there's a better way!
Alice fixtures can be a great help when you're writing some tests or even just filling up your system with dummy information. Here's some useful tips to keep in mind when writing fixtures with Alice.