Click here to Skip to main content
15,867,453 members

Comments by Gebbetje (Top 11 by date)

Gebbetje 8-Feb-11 4:08am View    
Thanks for your reply wizardzz and apologies for my late response.

>How large is the testing dataset?
The testing dataset should at least consist of 5 (mutual funds) x 60 (monthly returns) = 300 records. I would need a couple of those to be able to check different methods.

>Must you test every single peice of data in the DB? Typically you should be able to create
>some test cases based on certain scenarios and not have to do a full regression test.
I would need the full datasets (most of them consisting of 300 records) for testing purposes. Some tests though can use smaller datasets.


>What does the function signature look like? Are you able to create a wrapper
>function that plugs the data from the db to the function that processes it?
>If you do this, could you just unit test the wrapper function?
I'm using a DAL (Data Access Layer) to fill my objects, so it should be possible to create a wrapper that plugs the data, although that's something that I'm trying to prevent because I would have to write extra code (that could of its own contain bugs). Could such a setup not be better be implemented with mock objects / mocking? The problem with mock objects to my knowledge is that I would have to type in the data (in stead of reading them from a database).

>I'm thinking the database / large dataset aspect does not have to be managed by your test,
>but rather a function?
I'm not sure if I completely understand this point.
Gebbetje 4-Feb-11 4:48am View    
Hi wizardzz,
I'd like to (unit) test my project. If I run / debug it, and change code later, I'd like to be 100% sure that no other code breaks due to my changing some (other) part of the code.
Gebbetje 3-Feb-11 5:33am View    
I will. Thx.
Gebbetje 2-Feb-11 9:52am View    
The first link is interesting (as I already mentioned). It shows how to use a database as input for testing. Thanks for that. The database is used for input of (single) parameter values.
The second link has more the testing of a database and the methods to access the database as a focus.
The third link shows a decent number of articles that explain the basics of unit testing in Visual Studio.
My project though involves methods that do calculations on long time series (of mutual fund returns) that need at least 36 months of returns for multiple mutual funds. What I'm looking for is a tutorial on how to test this project (using one or a couple of fixed data sets). Any references?
Gebbetje 27-Jan-11 6:21am View    
"Code Coverage" doesn't seem to be included in Visual Studio 2008 Professional. Pity.