[erlang-questions] I Hate Unit Testing...

Masklinn masklinn@REDACTED
Wed Jan 28 13:51:57 CET 2009


On 28 Jan 2009, at 13:31 , Tim Watson wrote:

>> Familiarity is utmost so I just borrowed/subverted the term structure
>> used for .app files, like this...
>> ----- my_app.test ------
>> %% utest test specification
>> {utest, my_app,
>> [{description, ""},
>>  {version, "0.1"},
>>  {flags, [verbose]}, %% only [verbose] or [] supported
>>  {applications, [kernel, stdlib, crypto]}, %% dependencies
>>  {tests, [
>>       % Tests are specified as Module, Function, ArgumentList,  
>> ExpectedResult
>>       % i.e. {M, F, A, R}
>>   {my_module, hex, [2], "2"},
>>   {my_module, hex, [255], "ff"},
>>   {my_module, hex, [55551], "d8ff"}
>>  ]}
>> ]}.
>>
>
> I do like the declarative approach to defining tests. In Haskell, the
> QuickCheck tool assumes a similar idea
> (http://www.haskell.org/haskellwiki/ 
> QuickCheck_as_a_test_set_generator),
> albeit less tied to specific inputs/outputs.

There is an Erlang QuickCheck, but it's a commercial product by Quviq.




More information about the erlang-questions mailing list