Last week, it was my pleasure to present a new talk to the PHP Oxford user group, called “Why We Test”. A huge thanks to Oliver for inviting, and to everyone who came along.Be the first to leave a comment »
I’m back from this year’s PHP North West Conference, and finally have a few moments to talk about what was (yet again!) another excellent year.
I was there to present two talks – Introducing a Quality Model For MVC Applications, and Ways To Measure Your ORM’s Cost. It’s the first time since the php|cruise back in 2004 that I’ve presented twice at the same conference, and brings me up to something like 15 unique talks and workshops presented over the last 11 years.
I want to highlight one talk in particular from this year’s conference – Matt Cockayne talking about being a good code scout. This talk got promoted from the Unconference track to a spare slot on the Sunday morning. I’ve been thinking about pitching a keynote about how we all need to be great ambassadors for PHP, and I think Matt’s message would make a great keynote for our community.
Whether I’m speaking or just attending, I always enjoy the PHP North West Conference. Their conference team always do everything that they can to make each conference the best that it can be. In my opinion, the explosion of quality, community-based PHP conferences in Europe owes much to the example set particularly by PHP North West. We’ve come a long way from when I started speaking back in 2004
I’m really grateful that conference committees here in the UK – both PHP North West and PHP UK – continue to give me opportunities to come and talk at their conferences. Whether it’s about the problems of framework lock-in, component-based architectures, Git workflows, or indeed about driving quality, I’m often talking about things years before the PHP community moves that way. My work is often about solving problems most people don’t yet realise that they have, and that can’t be an easy sell, both within the committees that select talks for conferences nor to attendees when they’re buying their tickets.
This year’s conference may be over, but there’s no rest to be had.
- I’m already preparing another talk to deliver to the PHP Oxford user group later this month, called “Why Do We Test?” – expect plenty of ethical dilemmas in this one
- November sees me once again volunteering at Aberystwyth University, coaching 2nd year Comp Sci (and related) students on job hunting
- I’ll be speaking at PHP Surrey at the start of January 2016, possibly on writing a test suite for PHPFastCGI – you should come just to watch Andrew give his PHPFastCGI talk, it’s cry-out-loud funny
Here is the original blurb for this talk …
Your project has adopted an ORM such as Doctrine because it’s the quickest way to hook your code up to your database. Things are looking up, and your website is about to take off. Aaaand then the first complaints start to come in that your site isn’t coping with the new customers. You can’t find a problem in your own code. Could it be the ORM that’s the problem? How can you tell?
In this talk, Stuart will show you how you can use off-the-shelf open-source tools to work out what your ORM is doing, and whether or not it is the cause of your performance problems. He’ll show you how to measure the database itself and the ORM code, as well as providing useful strategies to reduce the cost of your ORM without having to abandon the ORM altogether. Finally, he’ll show you how you can extend these techniques to other parts of your application, so that you’re never in the dark again.Be the first to leave a comment »
Here’s the original blurb for this talk …
Your integration, functional and non-functional testing gives you a good idea if your code will work on Production. But how do you go about measuring the quality of code that already seems to work? How do you make that measurement repeatable? How do you share it with clients in government, finance or other large enterprises who are looking for a 3-5 year shelf-life from your code?
In this talk, Stuart will introduce you to SQuaRE, the international standard collection for software quality. He’ll give you a tour of all of the available and upcoming standards in this area, before taking a deep dive into the Product Quality Model from ISO/IEC 25010:2011. He’ll explain what a quality measurement is, how you link them to your project’s quality criteria, and how you incorporate them into code reviews, QA teams and management decisions.
You’ll leave this talk ready to start measuring and improving the quality of your product or service, with the tools you need to not only maintain quality but also to keep increasing it over time, even when faced with staff turnover.Be the first to leave a comment »
I’ve given several talks to user groups over the last few months, around the topics of testing and performance. I hope that you find them interesting and useful.
When To Mock
Mocking has not only become a mainstream practice in recent years, it has also become the default practice for many developers. In this talk, I present three questions that you should ask yourself first whenever you’re deciding if a mock is the right way to test your code, and some insight into how over-mocking ends up making your tests no better than having no tests at all.
This talk was presented to PHP Dorset in November, 2014.
How Much Does Your ORM Cost?
Whenever you use an ORM, you’re trying to reduce the time it takes to ship your code. But what are you trading in return? This lightning talk introduces the idea that ORMs aren’t entirely “free”, and hopes to start you thinking about how you might go about measuring just how much that ORM is really costing you.
This talk was presented to PHP South West (where I was once the answer to a pub quiz question – my claim to fame!) in April 2015.
The Mad Science of Testing
I’m a firm believer that good testing is also good science, and in this talk, I hope to convince you too. And if we’re going to be scientists, we might as well be mad scientists, because they have all the fun
This talk was presented to PHP Berkshire in June 2015.Be the first to leave a comment »
Back in 2009, I spoke at the PHP UK Conference about the pain of living with PHP’s fledgling frameworks, and I returned in 2011 to promote component-driven applications:
Back then, PEAR was the only tool available for distributing components. It was built in a time when hosting and sharing code was hard, and although PEAR made it possible to create components in PHP, PEAR never made it easy to do so.
Phix was an open-source tool that I wrote to sit on top of PEAR and make things easier. It gave you an easy-to-use build.xml file for Phing to automate all of the common tasks, a standardised file layout so that you could just drop in your code, and integration with Pirum so that you could build and publish.
Today, we don’t need any of these tools. PEAR has been replaced by Composer, and it’s so easy to use that there’s no need for Phing or a build.xml file. The PHP FIG standards have given us our file layouts, and as for publishing … today, all you need to do is push to GitHub and publishing happens automatically.
We no longer need Phix, and that’s a good thing.Be the first to leave a comment »
Storyplayer v1.5 has been released.
The major feature of this release is a complete overhaul of how test devices (such as web browsers) are managed inside Storyplayer, and integration with Sauce Labs for cross-browser testing. It also comes with the usual upgrades to support the latest Selenium Webdriver, Chrome, Chromedriver and Browsermob-Proxy releases. (full changelog)
I’ve also (finally!) completed the manual which covers:
- installation and configuration of Storyplayer
- what stories are, and their test phases
- how to write tests for your stories, and how to create your own Storyplayer modules
- how to create test environments to test your apps in – right from inside your tests!
- a comprehensive reference to every module that ships with Storyplayer
You can add Storyplayer to your projects using Composer – you’ll find the package as datasift/storyplayer – or download as an experimental PHAR. (Please make sure you’ve installed the necessary dependencies first!)
Any problems, please let me know.
Storyplayer is the open-source test automation tool built by DataSift. Use it to bring your user stories to life using plain old PHP #noDSL. Create test environments; deploy code; test with real browsers, shell commands, and any PHP code; and clean up afterwards – all from your tests. Write your tests once, and run them against your dev, test, staging and production environments. Storyplayer ships with 20 modules, including support for Vagrant, Amazon EC2, and ZeroMQ, and can easily be extended with your own plugins.Be the first to leave a comment »
Storyplayer is DataSift’s test tool for functional and non-functional testing of software and services, built to test at the firehose scale. It sits nicely between PHPUnit for unit testing by developers, and Behat for acceptance testing by product managers.
Here are the slides from that talk, for everyone who hasn’t yet seen them via Twitter:
If you can’t see the embedded slides in this blog post, they’re available over on SlideShare.
Right now, I’m focused on completing the online documentation (which is very much a work in progress), and preparing v1.1.0 with further improvements.Comments Off on Storyplayer Slides From PHP London Talk
Phix is a tool for creating and managing PHP components and tools and releasing them as PEAR packages.
I’ve pushed out Phix 0.16.0 this evening, with the following changes:
- phing build-vendor now removes the component’s own code from the vendor/ folder. (We build the vendor/ folder using PEAR, which installs the component into the vendor/ folder … sigh)
- An update to Phing changed the default behaviour of the <fileset> tag, breaking backwards-compatibility. I’ve updated our build.xml file to make the <fileset> tag revert back to its original behaviour.
To update your copy of Phix, please run:
pear upgrade phix/phix4componentdev
Any problems, please let me know.Be the first to leave a comment »
PHP is the world’s #1 programming language for creating websites. But it’s capable of so much more. How about real-time processing the social firehose?
Thanks to Brighton PHP for hosting this talk last month.Be the first to leave a comment »