git-svn-id: https://192.168.0.254/svn/Proyectos.LuisLeon_FactuGES2/trunk@68 b2cfbe5a-eba1-4a0c-8b32-7feea0a119f2
73 lines
1.7 KiB
ObjectPascal
73 lines
1.7 KiB
ObjectPascal
unit uTiendaWebController_test;
|
|
{
|
|
|
|
Delphi DUnit Test Case
|
|
----------------------
|
|
This unit contains a skeleton test case class generated by the Test Case Wizard.
|
|
Modify the generated code to correctly setup and call the methods from the unit
|
|
being tested.
|
|
|
|
}
|
|
|
|
interface
|
|
|
|
uses
|
|
TestFramework, uCustomEditor,
|
|
uTiendaWebController, uBizTiendaWeb;
|
|
|
|
type
|
|
// Test methods for class TClientesController
|
|
|
|
TestTTiendaWebController = class(TTestCase)
|
|
strict private
|
|
FTiendaWebController: ITiendaWebController;
|
|
FTiendaWeb : IBizTiendaWeb;
|
|
public
|
|
procedure SetUp; override;
|
|
procedure TearDown; override;
|
|
|
|
published
|
|
procedure TestActualizarTienda;
|
|
procedure TestDescargarPedidos;
|
|
end;
|
|
|
|
implementation
|
|
|
|
uses
|
|
schTiendaWebClient_Intf, uDADataTable, uDataModuleUsuarios,
|
|
SysUtils, Dialogs, uIDataModuleTiendaWeb,
|
|
uDataModuleTiendaWeb, uTiendaWebViewRegister, uHostMainForm,
|
|
uClientesController, uBizContactos;
|
|
|
|
{ TestTTiendaWebController }
|
|
|
|
procedure TestTTiendaWebController.SetUp;
|
|
begin
|
|
inherited;
|
|
FTiendaWebController := TTiendaWebController.Create;
|
|
FTiendaWeb := FTiendaWebController.Buscar(dmUsuarios.IDEmpresaActual);
|
|
end;
|
|
|
|
procedure TestTTiendaWebController.TearDown;
|
|
begin
|
|
inherited;
|
|
FTiendaWebController := NIL;
|
|
FTiendaWeb := NIL;
|
|
end;
|
|
|
|
procedure TestTTiendaWebController.TestActualizarTienda;
|
|
begin
|
|
FTiendaWebController.ActualizarTienda(FTiendaWeb);
|
|
end;
|
|
|
|
procedure TestTTiendaWebController.TestDescargarPedidos;
|
|
begin
|
|
FTiendaWebController.DescargarPedidos(FTiendaWeb);
|
|
end;
|
|
|
|
initialization
|
|
// Register any test cases with the test runner
|
|
RegisterTest(TestTTiendaWebController.Suite);
|
|
end.
|
|
|