← Back to team overview

elementary-dev-community team mailing list archive

Re: about TDD (Test Driven Development)

 

I do understand your point, and I agree with that. But what I want to
discuss is not if the TDD is generally a good approach ( hint. it is )
but if it's the right approach for a community driven project like
elementaryOS.

about this statement:
"So if you can test something in a language (if its build in or not) you
can run do TDD."

You should also consider the effort ( and the cost ). When using a
programming language that doesn't offer unit test facilities applying TDD
may be tedious and require lots of effort ( like writing your own test
suite engine ).

( as background, I'm used to agile methods, at work we use SCRUM and PRTI,
we are introducing TDD but at a slow rate )

BR,

Daniele


2013/9/3 Michael Lazarski <michael@xxxxxxxxxxx>

> **
>
> Hello,
>
> TDD isn't a Technic its a mindset or a philosophy.
>
> It came from the Agile manifesto http://agilemanifesto.org/ .
>
> So if you can test something in a language (if its build in or not) you
> can run do TDD.
>
> Often young developers don't see the need for writing test and even
> experienced hackers don't do.
>
> How often where you hunting a bug and you had to log stuff to hunt the bug?
>
> Or how often you see code and you go WTF?
>
> Here come test in handy. Now the young padawan may ask why?
>
> IF a test is good written you don't need to log stuff because when you
> break something the test will tell you what and where.
>
> Now the young padawan says: But should't I write good code instead?
>
> Yes, but the god like programmer is a Myth and if you think your a good
> hacker your probably a very bad one! << Facts !
>
> But how test can make me faster understand someones code?
>
> Simple: People how have Higher Mathematics in School/College/University
> probably have seen mathematical proofs.
>
> Most students think that Teachers do that to annoy the shit out of you but
> this is just wrong and you probably very bad at Mathematics too...
>
> In Mathematical proofs like in test we can see the essence of what the
> hacker wanted to do.
>
> By looking at what he tested and how we can understand how things works
> and how the shouldn't.
>
>
> SO you can not test and the code must be rewritten a lot like in
> contractor. maybe not today or maybe not in 1 or 2 months but at some point
> it will happen and if the guy how wrote the shitty code is not there
> anymore you will prey for test and a documentation of the code.
>
> OH and when people say: look at the source and you will understand it.
> they are pretty dumb too...
>
> Hacking is Art! If I look at the Mona Lisa and someone else will do we
> maybe see the same thing but think very different!
>
> So don't be dumb! Test and Document if you have the workflow right it will
> take not more then 10 minutes of a work hour but it will save letter tons
> and tons of work hours!
>
>
> Greetings lampe2
> Gruß Michael Lazarski
>
> --------------------------------------------------
> life simply so other people can simply life!
> Inspired by: https://vimeo.com/17576843
>
> -----Ursprüngliche Nachricht-----
> *Von:* Daniele S. <oppifjellet@xxxxxxxxx>
> *Gesendet:* Die 3 September 2013 13:40
> *An:* elementary-dev-community@xxxxxxxxxxxxxxxxxxx
> *Betreff:* [Elementary-dev-community] about TDD (Test Driven Development)
>
>
> I read some threads focusing on TDD, so I wanted to create one where we
> can continue that conversation without being offtopic.
>
> I'd say my two cent about TDD and elementary os development.
> In my opinion our current environment is obstile to TDD for serveral
> reason:
>
> 1. Vala doesn't support TDD out of the box (  other languages do:
> http://cobra-language.com/ )
> 2. GLib.Test is a unit test facility that is available to Vala
> applications, however it's not as advanced as CppUnit, NUnit and equivalent
> 3. TDD is great for libraries and backends, not so much for GUI
> applications and Database driven applications.
> 4. TDD needs lots of fakes and mocks to be written, and that could be very
> time expensive ( and tedious sometimes )
>
> Some references to Unit testing on vala apps:
> http://valadoc.org/#!api=glib-2.0/GLib.Test
> http://esite.ch/2012/06/26/writing-tests-for-vala/
>
> feel free to comment
>
> BR,
>
> Daniele "OpenNingia" Simonetti
>
> --
>
> Mailing list: https://launchpad.net/~elementary-dev-community
>
> Post to     : elementary-dev-community@xxxxxxxxxxxxxxxxxxx
>
> Unsubscribe : https://launchpad.net/~elementary-dev-community
>
> More help   : https://help.launchpad.net/ListHelp
>
>
> --
> Mailing list: https://launchpad.net/~elementary-dev-community
> Post to     : elementary-dev-community@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~elementary-dev-community
> More help   : https://help.launchpad.net/ListHelp
>
>

Follow ups

References