
![]() |
DangerMouse
Hi all,
Been reading quite a bit about test driven development, particularly with PHPUnit. What do you think of it as a methodology? Do you adopt it for all applications or only complex ones? (Next question would be what defines a complex app lol). How about 'behavoir driven development'?I'm a million miles away from being a professional coder, and don't really have alot of experience in actually 'doing', so to me this just seems like alot of extra coding, albeit leading to benefits in the long run, I'm just curious if you guys think its worth it? DM perkiset
Water cooler lingo and job security talk.
Sometimes I'll write a program to test for my result before I do my code, but in most cases, your "code" should be either fully outlined in your head or on paper before you ever start to code... the tests should already have succeeded *logically* before you touch the keyboard. The way they describe this at Wikipedia says that it started with the Extreme Programmingmovement - but it sounds more like the extremely time-costly method to me.Sort of silly sounding to me really. nop_90
Extreme
programmingdoes not work too well with "tradititional languages".It works well with the lisp/scheme/ pythonand maybe ruby familyThe reason is that in lisp/ python(i am not sure about ruby)you have a console which you can enter language definitions ie: define function etc at runtime where comes the power of this. a good example is where you have a large database csv data that has to be parsed. to load the data because it is so large lets say takes 10 minutes. so in ur handy console you create a function to load the data into some sort of data structure. u then from console in lisp compile the function (into actual machine instructions, inpythons case it goes to byte-code).you then load ur data. next u create a function to do queries against it. in the traditional language, you would have to recompile, reload data, losing 10 minutes. in lisp/ pythonyou just compile the function,and then run it, if it has a bug, in lisp you can walk its stack, and abort, get back to console and fix. in C/C++/ phpetc u would have to recompile the entire proggie and restart. (hence losing the 10 minutes)in the case of OO in lisp's case, (and probably python ![]() you create an object then u decide to change the class definition of the object. you can then create an "update" function that walks the objects created. it will then update at runtime ur already created objects. this is not only very powerful for testing new ideas quickly, but also for other things. like lets say you where serializing the objects, and saving them, to reload later. well as u reload the object off the disk, if it is an earlier version, it will automatically update them. this is extremely powerful for things like object databases. http://www.zope.org/Documentation/Articles/ZODB1 all of the complexity of a traditional database is gone. anyway in a nutshell if u are using phpit probably is a waste of time. |

Thread Categories

![]() |
![]() |
Best of The Cache Home |
![]() |
![]() |
Search The Cache |
- Ajax
- Apache & mod_rewrite
- BlackHat SEO & Web Stuff
- C/++/#, Pascal etc.
- Database Stuff
- General & Non-Technical Discussion
- General programming, learning to code
- Javascript Discussions & Code
- Linux Related
- Mac, iPhone & OS-X Stuff
- Miscellaneous
- MS Windows Related
- PERL & Python Related
- PHP: Questions & Discussion
- PHP: Techniques, Classes & Examples
- Regular Expressions
- Uncategorized Threads