Foodolini.Database.Test.PictureTest Class Reference

Unit test to the Database layer of Picture. More...

Inherits Foodolini::Database::Test::DatabaseTest.

Collaboration diagram for Foodolini.Database.Test.PictureTest:
Collaboration graph

List of all members.

Public Member Functions

void LoadStressTestVector ()
 Create 5 MiB pseudo random data for stress testing :).
void CreateTable ()
 Test that creates a table.
void Save ()
 Test that tries to save a simple picture.
void SaveLoad ()
 Test that saves and load a picture.
void StressTest ()
 Stress test the database by loading and saving a large picture.

Static Private Attributes

static readonly byte[] smallTestVector = {45, 78, 92, 0, 1,2, 34}
 Small test vector.
static readonly byte[] stressTestVector = new byte[5 * 1024 * 1024]
 Large test vector for stress testing (5 MiB).

Detailed Description

Unit test to the Database layer of Picture.

Definition at line 11 of file PictureTest.cs.


Member Function Documentation

void Foodolini.Database.Test.PictureTest.CreateTable (  ) 

Test that creates a table.

Definition at line 39 of file PictureTest.cs.

void Foodolini.Database.Test.PictureTest.LoadStressTestVector (  ) 

Create 5 MiB pseudo random data for stress testing :).

The c

Definition at line 20 of file PictureTest.cs.

void Foodolini.Database.Test.PictureTest.Save (  ) 

Test that tries to save a simple picture.

Please note that this test will also automatically create a Pictures table on-the-fly, so if the CreateTable test failed, this test is likely to fail too. However, this test does *not* depend on the CreateTable test.

Definition at line 52 of file PictureTest.cs.

void Foodolini.Database.Test.PictureTest.SaveLoad (  ) 

Test that saves and load a picture.

Definition at line 64 of file PictureTest.cs.

void Foodolini.Database.Test.PictureTest.StressTest (  ) 

Stress test the database by loading and saving a large picture.

This test uses 5 MiB pseudo random test vector generated in PictureTest.LoadStressTestVector()

Definition at line 95 of file PictureTest.cs.


Member Data Documentation

readonly byte [] Foodolini.Database.Test.PictureTest.smallTestVector = {45, 78, 92, 0, 1,2, 34} [static, private]

Small test vector.

Definition at line 28 of file PictureTest.cs.

readonly byte [] Foodolini.Database.Test.PictureTest.stressTestVector = new byte[5 * 1024 * 1024] [static, private]

Large test vector for stress testing (5 MiB).

Definition at line 33 of file PictureTest.cs.


The documentation for this class was generated from the following file:

Foodolini 1.0.0 Documentation, generated with DoxyGen.