1,987 reputation
719
bio website gordiansolution.co.uk
location United Kingdom
age
visits member for 2 years, 10 months
seen Mar 27 at 10:29

I'm a professional PHP programmer with almost a decade of professional experience and considerably more as a hobbyist programmer. I've also had some exposure to Java, Object Pascal and am interested in learning objective C

I've started work on a PHP framework, though it's still at a very early stage and not yet really useful. The current source is available on GitHub.

I've also begun development of a CSS3 elastic grid for use on my own projects and had published that on GitHub as well.


Jan
5
awarded  Commentator
Jan
4
comment I've unit tested my class, now how do I get started with an integration test?
I would add that scenario testing is probably not really something PHPUnit is suited to. Yu might want to look at some tool you can run in a browser such as Selenium, or a tool that can simulate a browser, like jMeter.
Jan
4
comment I've unit tested my class, now how do I get started with an integration test?
+1 for good question, but also voted to migrate to Programmers. Seems that's where questions on testing strategies belong
Jan
4
comment Is this the correct approach to an OOP design structure in php?
You might want to consider implementing an autoloader instead of explicitly requiring everything.
Jan
3
awarded  Citizen Patrol
Jan
2
comment Unit testing methods with indeterminate output
Actually, the class is designed such that the password is generated on the first call to getPassword () and then latches, so it always returns the same password for the lifetime of the object. My test suite already checks that multiple calls to getPassword () on the same password instance always returns the same password string. As for thread-safety, that's not really a concern in PHP :)
Jan
2
answered Unit testing methods with indeterminate output
Jan
2
awarded  Student
Jan
2
awarded  Scholar
Jan
2
awarded  Nice Question
Jan
1
comment Unit testing methods with indeterminate output
All the answers given had good suggestions that I used, but this is the one that I think nails the core issue so it gets the accept.
Jan
1
comment Unit testing methods with indeterminate output
The regex you gave proved useful so I included a tweaked version in my test. Thanks.
Jan
1
comment Unit testing methods with indeterminate output
The PW class maintains a constant that's essentially the pool of characters the password should be generated from. By subclassing it and overriding the constant with a single character I managed to eliminate one area of non-determinacy for the purposes of testing. So thanks.
Jan
1
comment Unit testing methods with indeterminate output
Huh, thanks for the comment. Didn't even notice that, but now I'm wondering the same thing. Only thing I could think of is that's about a general case rather than a specific one, but I could just post the source for the above-mentioned password class and ask "How do I test that class?" instead of "How do I test any indeterminate class?"
Jan
1
asked Unit testing methods with indeterminate output
Jun
23
awarded  Teacher
Jun
23
awarded  Supporter
Jun
23
answered I need to know the reasons why learning Linux Shell Scripting (BASH) benefits me as a PHP developer
Oct
16
comment What is negative code?
@JBRWilkinson: I'd say that there is a "sweet spot" regarding code brevity. Generally, shorter is better, but there comes a point when code can grow too terse and not be easy to decipher to another programmer.