Friday, 24 October 2014

Would you install a ColdFusion hotfix/updater/patch without testing?

G'day:
First things first, this is my position (and the one I believe anyone who's not a lunatic should have): "bloody hell no, are you insane?"

But I polled the community yesterday, via Twitter:



Tuesday, 21 October 2014

CFCamp 2014 hindsight

G'day:
So CFCamp 2014 is over. First things first: Mike, you're a star. Everyone who attended thinks this. Thanks so much for organising yet another excellent CFCamp, and dealing with all the various... erm... "idiosyncracies" that sponsors and speakers and others threw at you.

I'm not flying out until tomorrow afternoon, and I don't fancy going into Munich for a night out, so I'm just hanging @ the Stadthalle in Germering. As I just said on Twitter: I seem to have the place to myself, other than the four people working on the bar here. I'll probably go over to visit my favourite wolpertinger later on for dinner, but it's too early for that. So beer and blogging it is. I've just started my third pint (well: 400ml rather than a pint, anyhow).

This is my wash-up of the conference.

A quick look at DI/1

G'day:
I'm at CFCamp at the moment, and one of the better presentations yesterday (out of a lot of good presentations, I might add) was Chris' presentation, "Dependency Injection with DI/1". It looked sufficiently interesting I thought I'd have a quick look-see at it. I have downloaded it in the past, but that's about as far as I had got.

I've been using ColdSpring at work for the last few years, but DI has come a long way since ColdSpring's heyday. So I'm familiar with the concepts of dependency injection, but only ColdSpring's implementation of it.

If you don't know what DI is, go read up on it first otherwise none of this will be very meaningful. I'm not able to get an internet connection at the moment, so I can't find a decent link for you, but I'll try to remember to update this later on. Or, hey, you probably know how Google works.

Monday, 20 October 2014

CFCamp: a Crocodile Dundee moment for me

G'day:

That's not a shot glass. This is a shotglass.

It was a bit of a messy night last night. Well, indeed, we basically sat around all afternoon @ the Stadthalle at Germering drinking Tegernseer Hell, so it was getting messy even before the evening.

Am currently sitting in Luis' CommandBox presentation. CommandBox continues to look impressive.

Quite a content-lite article this. I just liked the size of that shotglass, basically.

I'll try to write something more useful later on. But I'm also doing Twitter updates tagged with "#CFCamp" as things occur to me. That might be a better way to find out about what's going on @ CFCamp.

--
Adam

Saturday, 18 October 2014

PHP: getting AspectMock to work

G'day:
First things first: Luis, Brad, everyone at Ortus Solutions: I bloody love you guys. Working with TestBox and MockBox is an absolute pleasure compared to getting their PHP equivalents installed and working properly.

Over the last coupla weeks, meself and Duncan have been investigating unit testing on PHP, and specifically how to mock dependencies. On our old CFML code base, we have 1000s of test, and we use MockBox heavily, as we have rather a lot of dependencies which interfere with testing if they're not mocked. We only ever really moved to TestBox as a proof-of-concept before our CFML codebase was put into maintenance mode, and we shifted to PHP. Prior to that we had been using MXUnit for a number of years.

PHPUnit is a bit rough-and-ready in comparison to TestBox, but it's solid and will do the trick. However we both had an arsehole of a time getting AspectMock to work. And we both failed and moved on to other things. Earlier I'd looked at Mockery as a solution for mocking - its docs are better than AspectMock's (both a recommendation for Mockery, and an indictment of AspectMock), but it did not do something things we expect to need to be doing, whereas AspectMock claims it can (mocking static methods).

Anyway, this afternoon I found myself furrowing my brow and thought "I'm going to get that bloody thing to work... or else". Fortunately after a lot of swearing and wondering if I can hunt down and punish AspectMock's author... I finally noticed what I had been doing wrong. I presume Duncan was doing the same thing wrong, but don't know. Anyway, I got it working.

So here's my AspectMock mission from this afternoon.

TickintheBox

G'day:
I watched a good amount of bickering between two fellas who should know better last night:


(click through and read the "conversation" if you want to. I'll not reproduce it here as it's a bit embarrassing for the participants, I think).

Also, I "published" some misinformation of my own about CommandBox a day or so ago (as a comment on Cutter's blog:  "What's Wrong With ColdFusion - 2014 Edition"). So I figured I owed to Brad and Luis to actually have a look at CommandBox (which I do like the sound of, see "Ortus does what Adobe / Railo ought to have done...").