C# Класс Nettiers.AdventureWorks.UnitTests.EmployeeTest

Provides tests for the and Employee objects (entity, collection and repository).
Показать файл Открыть проект Примеры использования класса

Защищенные свойства (Protected)

Свойство Тип Описание
mock Nettiers.AdventureWorks.Entities.Employee
mockCollection TList

Открытые методы

Метод Описание
CleanUp_Generated ( ) : void

This method is used to restore the environment after the tests are completed.

CreateMockInstance ( TransactionManager tm ) : Employee

Returns a Typed Employee Entity with mock values.

CreateMockInstance_Generated ( TransactionManager tm ) : Employee

Returns a Typed Employee Entity with mock values.

EmployeeTest ( ) : System

Creates a new EmployeeTest instance.

Init_Generated ( ) : void

This method is used to construct the test environment prior to running the tests.

UpdateMockInstance ( TransactionManager tm, Employee mock ) : void

Update the Typed Employee Entity with modified mock values.

UpdateMockInstance_Generated ( TransactionManager tm, Employee mock ) : void

Update the Typed Employee Entity with modified mock values.

Защищенные методы

Метод Описание
CreateTransaction ( ) : TransactionManager

Приватные методы

Метод Описание
Dispose ( ) : void
Init ( ) : void
SetSpecialTestData ( Employee mock ) : void

Make any alterations necessary (i.e. for DB check constraints, special test cases, etc.)

Step_01_Insert ( ) : void
Step_01_Insert_Generated ( ) : void

Inserts a mock Employee entity into the database.

Step_02_SelectAll ( ) : void
Step_02_SelectAll_Generated ( ) : void

Selects all Employee objects of the database.

Step_03_DeepLoad ( ) : void
Step_03_DeepLoad_Generated ( ) : void

Deep load all Employee children.

Step_04_Update ( ) : void
Step_04_Update_Generated ( ) : void

Updates a mock Employee entity into the database.

Step_05_Delete ( ) : void
Step_05_Delete_Generated ( ) : void

Delete the mock Employee entity into the database.

Step_06_SerializeEntity ( ) : void
Step_06_SerializeEntity_Generated ( ) : void

Serialize the mock Employee entity into a temporary file.

Step_07_DeserializeEntity ( ) : void
Step_07_DeserializeEntity_Generated ( ) : void

Deserialize the mock Employee entity from a temporary file.

Step_08_SerializeCollection ( ) : void
Step_08_SerializeCollection_Generated ( ) : void

Serialize a Employee collection into a temporary file.

Step_09_DeserializeCollection ( ) : void
Step_09_DeserializeCollection_Generated ( ) : void

Deserialize a Employee collection from a temporary file.

Step_10_FK ( ) : void
Step_10_FK_Generated ( ) : void

Check the foreign key dal methods.

Step_11_IX ( ) : void
Step_11_IX_Generated ( ) : void

Check the indexes dal methods.

Step_20_TestEntityHelper ( ) : void
Step_20_TestEntityHelper_Generated ( ) : void

Test methods exposed by the EntityHelper class.

Step_30_TestFindByQuery ( ) : void
Step_30_TestFindByQuery_Generated ( ) : void

Test Find using the Query class

Описание методов

CleanUp_Generated() статический публичный Метод

This method is used to restore the environment after the tests are completed.
static public CleanUp_Generated ( ) : void
Результат void

CreateMockInstance() статический публичный Метод

Returns a Typed Employee Entity with mock values.
static public CreateMockInstance ( TransactionManager tm ) : Employee
tm TransactionManager
Результат Nettiers.AdventureWorks.Entities.Employee

CreateMockInstance_Generated() статический публичный Метод

Returns a Typed Employee Entity with mock values.
static public CreateMockInstance_Generated ( TransactionManager tm ) : Employee
tm TransactionManager
Результат Nettiers.AdventureWorks.Entities.Employee

CreateTransaction() защищенный статический Метод

protected static CreateTransaction ( ) : TransactionManager
Результат TransactionManager

EmployeeTest() публичный Метод

Creates a new EmployeeTest instance.
public EmployeeTest ( ) : System
Результат System

Init_Generated() статический публичный Метод

This method is used to construct the test environment prior to running the tests.
static public Init_Generated ( ) : void
Результат void

UpdateMockInstance() статический публичный Метод

Update the Typed Employee Entity with modified mock values.
static public UpdateMockInstance ( TransactionManager tm, Employee mock ) : void
tm TransactionManager
mock Nettiers.AdventureWorks.Entities.Employee
Результат void

UpdateMockInstance_Generated() статический публичный Метод

Update the Typed Employee Entity with modified mock values.
static public UpdateMockInstance_Generated ( TransactionManager tm, Employee mock ) : void
tm TransactionManager
mock Nettiers.AdventureWorks.Entities.Employee
Результат void

Описание свойств

mock защищенное свойство

protected Employee,Nettiers.AdventureWorks.Entities mock
Результат Nettiers.AdventureWorks.Entities.Employee

mockCollection защищенное свойство

protected TList mockCollection
Результат TList