Refactored, adjusted, retested and moved tests

This commit is contained in:
Ezequiel Juliano Müller 2015-12-22 09:29:25 -02:00
parent 5f1b06c158
commit 39d19db773
30 changed files with 4885 additions and 3439 deletions

40
unittests/CleanUp.bat Normal file
View File

@ -0,0 +1,40 @@
@echo off
echo Cleaning...
del /f /q /s *.bak
del /f /q /s *.dcu
del /f /q /s *.ddp
del /f /q /s *.~*
del /f /q /s *.local
del /f /q /s *.identcache
del /f /q /s *.tvsconfig
del /f /q /s *.bpl
del /f /q /s *.cbk
del /f /q /s *.dcp
del /f /q /s *.dsk
del /f /q /s *.o
del /f /q /s *.rsm
del /f /q /s *.skincfg
del /f /q /s *.log
del /f /q /s *.stat
for /f "tokens=* delims=" %%i in ('dir /s /b /a:d __history') do (
rd /s /q "%%i"
)
for /f "tokens=* delims=" %%i in ('dir /s /b /a:d __recovery') do (
rd /s /q "%%i"
)
for /f "tokens=* delims=" %%i in ('dir /s /b /a:d Win32') do (
rd /s /q "%%i"
)
for /f "tokens=* delims=" %%i in ('dir /s /b /a:d Win64') do (
rd /s /q "%%i"
)
if "%1"=="" goto :eof
pause

View File

@ -0,0 +1,72 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{5EB37CAE-9429-40A4-8DA0-11C36BB79C42}</ProjectGuid>
</PropertyGroup>
<ItemGroup>
<Projects Include="TestServer\TestServer.dproj">
<Dependencies/>
</Projects>
<Projects Include="Several\DMVCFrameworkTests.dproj">
<Dependencies/>
</Projects>
<Projects Include="RESTClient\RESTClientTests.dproj">
<Dependencies/>
</Projects>
<Projects Include="StandaloneServer\StandaloneServerTests.dproj">
<Dependencies/>
</Projects>
</ItemGroup>
<ProjectExtensions>
<Borland.Personality>Default.Personality.12</Borland.Personality>
<Borland.ProjectType/>
<BorlandProject>
<Default.Personality/>
</BorlandProject>
</ProjectExtensions>
<Target Name="TestServer">
<MSBuild Projects="TestServer\TestServer.dproj"/>
</Target>
<Target Name="TestServer:Clean">
<MSBuild Projects="TestServer\TestServer.dproj" Targets="Clean"/>
</Target>
<Target Name="TestServer:Make">
<MSBuild Projects="TestServer\TestServer.dproj" Targets="Make"/>
</Target>
<Target Name="DMVCFrameworkTests">
<MSBuild Projects="Several\DMVCFrameworkTests.dproj"/>
</Target>
<Target Name="DMVCFrameworkTests:Clean">
<MSBuild Projects="Several\DMVCFrameworkTests.dproj" Targets="Clean"/>
</Target>
<Target Name="DMVCFrameworkTests:Make">
<MSBuild Projects="Several\DMVCFrameworkTests.dproj" Targets="Make"/>
</Target>
<Target Name="RESTClientTests">
<MSBuild Projects="RESTClient\RESTClientTests.dproj"/>
</Target>
<Target Name="RESTClientTests:Clean">
<MSBuild Projects="RESTClient\RESTClientTests.dproj" Targets="Clean"/>
</Target>
<Target Name="RESTClientTests:Make">
<MSBuild Projects="RESTClient\RESTClientTests.dproj" Targets="Make"/>
</Target>
<Target Name="StandaloneServerTests">
<MSBuild Projects="StandaloneServer\StandaloneServerTests.dproj"/>
</Target>
<Target Name="StandaloneServerTests:Clean">
<MSBuild Projects="StandaloneServer\StandaloneServerTests.dproj" Targets="Clean"/>
</Target>
<Target Name="StandaloneServerTests:Make">
<MSBuild Projects="StandaloneServer\StandaloneServerTests.dproj" Targets="Make"/>
</Target>
<Target Name="Build">
<CallTarget Targets="TestServer;DMVCFrameworkTests;RESTClientTests;StandaloneServerTests"/>
</Target>
<Target Name="Clean">
<CallTarget Targets="TestServer:Clean;DMVCFrameworkTests:Clean;RESTClientTests:Clean;StandaloneServerTests:Clean"/>
</Target>
<Target Name="Make">
<CallTarget Targets="TestServer:Make;DMVCFrameworkTests:Make;RESTClientTests:Make;StandaloneServerTests:Make"/>
</Target>
<Import Project="$(BDS)\Bin\CodeGear.Group.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Group.Targets')"/>
</Project>

View File

@ -0,0 +1,121 @@
unit MVCFramework.Tests.AppController;
interface
uses
System.SysUtils,
System.Generics.Collections,
System.Classes,
MVCFramework,
MVCFramework.Commons,
MVCFramework.Server;
type
TAppUser = class
strict private
FCod: Integer;
FName: string;
FPass: string;
public
property Cod: Integer read FCod write FCod;
property Name: string read FName write FName;
property Pass: string read FPass write FPass;
end;
[MVCPath('/')]
TAppController = class(TMVCController)
public
[MVCPath('/hello')]
[MVCHTTPMethod([httpGET])]
procedure HelloWorld(ctx: TWebContext);
[MVCPath('/user')]
[MVCHTTPMethod([httpGET])]
procedure GetUser(ctx: TWebContext);
[MVCPath('/user/save')]
[MVCHTTPMethod([httpPOST])]
procedure PostUser(ctx: TWebContext);
[MVCPath('/users')]
[MVCHTTPMethod([httpGET])]
procedure GetUsers(ctx: TWebContext);
[MVCPath('/users/save')]
[MVCHTTPMethod([httpPOST])]
procedure PostUsers(ctx: TWebContext);
end;
implementation
{ TAppController }
procedure TAppController.GetUser(ctx: TWebContext);
var
vUser: TAppUser;
begin
vUser := TAppUser.Create;
vUser.Cod := 1;
vUser.Name := 'Ezequiel';
vUser.Pass := '123';
Render(vUser);
end;
procedure TAppController.GetUsers(ctx: TWebContext);
var
vUsers: TObjectList<TAppUser>;
vUser: TAppUser;
I: Integer;
begin
vUsers := TObjectList<TAppUser>.Create(True);
for I := 0 to 10 do
begin
vUser := TAppUser.Create;
vUser.Cod := I;
vUser.Name := 'Ezequiel ' + IntToStr(I);
vUser.Pass := IntToStr(I);
vUsers.Add(vUser);
end;
Self.Render<TAppUser>(vUsers);
end;
procedure TAppController.HelloWorld(ctx: TWebContext);
begin
Render('Hello World called with GET');
end;
procedure TAppController.PostUser(ctx: TWebContext);
var
vUser: TAppUser;
begin
vUser := ctx.Request.BodyAs<TAppUser>();
if (vUser.Cod > 0) then
Render('Sucess!')
else
Render('Error!');
FreeAndNil(vUser);
end;
procedure TAppController.PostUsers(ctx: TWebContext);
var
vUsers: TObjectList<TAppUser>;
begin
vUsers := ctx.Request.BodyAsListOf<TAppUser>();
vUsers.OwnsObjects := True;
if (vUsers.Count > 0) then
Render('Sucess!')
else
Render('Error!');
FreeAndNil(vUsers);
end;
end.

View File

@ -0,0 +1,291 @@
unit MVCFramework.Tests.RESTClient;
interface
uses
TestFramework,
System.Classes,
System.SysUtils,
System.Generics.Collections,
ObjectsMappers,
MVCFramework,
MVCFramework.Server,
MVCFramework.RESTClient,
MVCFramework.RESTAdapter,
MVCFramework.Commons,
MVCFramework.Tests.AppController;
type
IAppResource = interface(IInvokable)
['{D139CD79-CFE5-49E3-8CFB-27686621911B}']
[RESTResource(TMVCHTTPMethodType.httpGET, '/hello')]
function HelloWorld(): string;
[RESTResource(TMVCHTTPMethodType.httpGET, '/user')]
function GetUser(): TAppUser;
[RESTResource(TMVCHTTPMethodType.httpPOST, '/user/save')]
procedure PostUser([Body] pBody: TAppUser);
[RESTResource(TMVCHTTPMethodType.httpGET, '/users')]
[MapperListOf(TAppUser)]
function GetUsers(): TObjectList<TAppUser>;
[RESTResource(TMVCHTTPMethodType.httpPOST, '/users/save')]
[MapperListOf(TAppUser)]
procedure PostUsers([Body] pBody: TObjectList<TAppUser>);
end;
TTestRESTClient = class(TTestCase)
strict private
FRESTClient: TRESTClient;
FRESTAdapter: TRESTAdapter<IAppResource>;
FAppResource: IAppResource;
protected
procedure SetUp; override;
procedure TearDown; override;
published
procedure TestCreateAndDestroy();
procedure TestInformation();
procedure TestHelloWorld();
procedure TestGetUser();
procedure TestPostUser();
procedure TestPostUsers();
procedure TestGetUsers();
end;
implementation
uses
MVCFramework.Tests.WebModule;
{ TTestRESTClient }
procedure TTestRESTClient.SetUp;
var
vServerInfo: IMVCServerInfo;
vOnAuthentication: TMVCAuthenticationDelegate;
begin
inherited;
vServerInfo := TMVCServerInfoFactory.Build;
vServerInfo.ServerName := 'ServerApp';
vServerInfo.Port := 3000;
vServerInfo.MaxConnections := 1024;
vServerInfo.WebModuleClass := TestWebModuleClass;
vOnAuthentication := procedure(const AUserName, APassword: string;
AUserRoles: TList<string>; var AIsValid: Boolean)
begin
AIsValid := AUserName.Equals('ezequiel') and APassword.Equals('123');
end;
vServerInfo.Security := TMVCDefaultSecurity.Create(vOnAuthentication, nil);
MVCServerDefault.Container.CreateServer(vServerInfo);
MVCServerDefault.Container.StartServers;
FRESTClient := TRESTClient.Create('localhost', 3000);
FRESTAdapter := TRESTAdapter<IAppResource>.Create;
FRESTAdapter.Build(FRESTClient);
FAppResource := FRESTAdapter.ResourcesService;
end;
procedure TTestRESTClient.TearDown;
begin
inherited;
MVCServerDefault.Container.StopServers;
FreeAndNil(FRESTClient);
end;
procedure TTestRESTClient.TestCreateAndDestroy;
var
vClient: TRESTClient;
begin
vClient := TRESTClient.Create('', 80, nil);
CheckTrue(vClient <> nil);
FreeAndNil(vClient);
CheckTrue(vClient = nil);
end;
procedure TTestRESTClient.TestGetUser;
var
vUser: TAppUser;
vResp: IRESTResponse;
begin
FRESTClient.Resource('/user').Params([]);
FRESTClient.Authentication('ezequiel', '123');
// String
vResp := FRESTClient.doGET;
CheckTrue(
('{"Cod":1,"Name":"Ezequiel","Pass":"123"}' = vResp.BodyAsString) and
(vResp.ResponseCode = 200)
);
// Object
vUser := FRESTClient.doGET.BodyAsJSONObject.AsObject<TAppUser>();
try
CheckTrue((vUser <> nil) and (vUser.Cod > 0));
finally
FreeAndNil(vUser);
end;
// Adapter
vUser := FAppResource.GetUser;
try
CheckTrue((vUser <> nil) and (vUser.Cod > 0));
finally
FreeAndNil(vUser);
end;
end;
procedure TTestRESTClient.TestGetUsers;
var
vUsers: TObjectList<TAppUser>;
begin
FRESTClient.Resource('/users').Params([]);
FRESTClient.Authentication('ezequiel', '123');
// String
CheckEqualsString('[{"Cod":0,"Name":"Ezequiel 0","Pass":"0"},{"Cod":1,"Name":"Ezequiel 1","Pass":"1"},' +
'{"Cod":2,"Name":"Ezequiel 2","Pass":"2"},{"Cod":3,"Name":"Ezequiel 3","Pass":"3"},{"Cod":4,"Name":"Ezequiel 4","Pass":"4"},' +
'{"Cod":5,"Name":"Ezequiel 5","Pass":"5"},{"Cod":6,"Name":"Ezequiel 6","Pass":"6"},{"Cod":7,"Name":"Ezequiel 7","Pass":"7"},' +
'{"Cod":8,"Name":"Ezequiel 8","Pass":"8"},{"Cod":9,"Name":"Ezequiel 9","Pass":"9"},{"Cod":10,"Name":"Ezequiel 10","Pass":"10"}]',
FRESTClient.doGET.BodyAsString);
// Objects
vUsers := FRESTClient.doGET.BodyAsJSONArray.AsObjectList<TAppUser>;
try
vUsers.OwnsObjects := True;
CheckTrue(vUsers.Count > 0);
finally
FreeAndNil(vUsers);
end;
// Adapter
vUsers := FAppResource.GetUsers;
try
vUsers.OwnsObjects := True;
CheckTrue(vUsers.Count > 0);
finally
FreeAndNil(vUsers);
end;
end;
procedure TTestRESTClient.TestHelloWorld;
begin
FRESTClient.Resource('/hello').Params([]);
FRESTClient.Authentication('ezequiel', '123');
// String
CheckEqualsString('"Hello World called with GET"', FRESTClient.doGET.BodyAsString);
// Adapter
CheckEqualsString('"Hello World called with GET"', FAppResource.HelloWorld);
end;
procedure TTestRESTClient.TestInformation;
var
vClient: TRESTClient;
begin
vClient := TRESTClient.Create('', 80, nil);
vClient
.ReadTimeOut(100)
.ConnectionTimeOut(100)
.Authentication('dmvc', 'dmvc', True)
.Accept(TMVCMediaType.APPLICATION_JSON)
.AcceptCharSet(TMVCCharset.UTF_8)
.ContentType(TMVCMediaType.APPLICATION_JSON)
.ContentCharSet(TMVCCharset.UTF_8)
.ContentEncoding(TMVCCharset.UTF_8)
.SSL
.Compression;
CheckTrue(vClient.ReadTimeOut = 100);
CheckTrue(vClient.ConnectionTimeOut = 100);
CheckTrue(vClient.Username = 'dmvc');
CheckTrue(vClient.Password = 'dmvc');
CheckTrue(vClient.UseBasicAuthentication);
CheckTrue(vClient.Accept = 'application/json;charset=UTF-8');
CheckTrue(vClient.ContentType = 'application/json;charset=UTF-8');
CheckTrue(vClient.ContentEncoding = 'UTF-8');
CheckTrue(vClient.HasSSL);
CheckTrue(vClient.HasCompression);
CheckTrue(vClient.RawBody <> nil);
CheckTrue(vClient.MultiPartFormData <> nil);
CheckTrue(vClient.BodyParams <> nil);
CheckTrue(vClient.RequestHeaders <> nil);
CheckTrue(vClient.QueryStringParams <> nil);
FreeAndNil(vClient);
end;
procedure TTestRESTClient.TestPostUser;
var
vUser: TAppUser;
vResp: IRESTResponse;
begin
FRESTClient.Resource('/user/save').Params([]);
FRESTClient.Authentication('ezequiel', '123');
vUser := TAppUser.Create;
vUser.Cod := 1;
vUser.Name := 'Ezequiel';
vUser.Pass := '123';
vResp := FRESTClient.doPOST<TAppUser>(vUser);
CheckTrue(('"Sucess!"' = vResp.BodyAsString) and (vResp.ResponseCode = 200));
// Adapter
vUser := TAppUser.Create;
vUser.Cod := 1;
vUser.Name := 'Ezequiel';
vUser.Pass := '123';
FAppResource.PostUser(vUser);
end;
procedure TTestRESTClient.TestPostUsers;
var
vUsers: TObjectList<TAppUser>;
vResp: IRESTResponse;
I: Integer;
vUser: TAppUser;
begin
FRESTClient.Resource('/users/save').Params([]);
FRESTClient.Authentication('ezequiel', '123');
FRESTClient.Accept('application/json;charset=utf-8');
FRESTClient.ContentType('application/json;charset=utf-8');
vUsers := TObjectList<TAppUser>.Create(True);
for I := 0 to 10 do
begin
vUser := TAppUser.Create;
vUser.Cod := I;
vUser.Name := 'Ezequiel öüáàçãõºs ' + IntToStr(I);
vUser.Pass := IntToStr(I);
vUsers.Add(vUser);
end;
vResp := FRESTClient.doPOST<TAppUser>(vUsers);
CheckTrue(('"Sucess!"' = vResp.BodyAsString) and (vResp.ResponseCode = 200));
// Adapter
vUsers := TObjectList<TAppUser>.Create(True);
for I := 0 to 10 do
begin
vUser := TAppUser.Create;
vUser.Cod := I;
vUser.Name := 'Ezequiel öüáàçãõºs ' + IntToStr(I);
vUser.Pass := IntToStr(I);
vUsers.Add(vUser);
end;
FAppResource.PostUsers(vUsers);
end;
initialization
RegisterTest(TTestRESTClient.Suite);
end.

View File

@ -0,0 +1,55 @@
unit MVCFramework.Tests.WebModule;
interface
uses
System.SysUtils,
System.Classes,
Web.HTTPApp,
MVCFramework;
type
TTestWebModule = class(TWebModule)
procedure WebModuleCreate(Sender: TObject);
procedure WebModuleDestroy(Sender: TObject);
private
FMVCEngine: TMVCEngine;
public
{ Public declarations }
end;
var
TestWebModuleClass: TComponentClass = TTestWebModule;
implementation
uses
MVCFramework.Tests.RESTClient,
MVCFramework.Middleware.Authentication,
MVCFramework.Tests.AppController,
MVCFramework.Server;
{$R *.dfm}
procedure TTestWebModule.WebModuleCreate(Sender: TObject);
var
vServer: IMVCServer;
begin
FMVCEngine := TMVCEngine.Create(Self);
// Add Controller
FMVCEngine.AddController(TAppController);
// Add Security Middleware
vServer := MVCServerDefault.Container.FindServerByName('ServerApp');
if (vServer <> nil) and (vServer.Info.Security <> nil) then
FMVCEngine.AddMiddleware(TMVCBasicAuthenticationMiddleware.Create(vServer.Info.Security));
end;
procedure TTestWebModule.WebModuleDestroy(Sender: TObject);
begin
FreeAndNil(FMVCEngine);
end;
end.

View File

@ -0,0 +1,31 @@
program RESTClientTests;
{
Delphi DUnit Test Project
-------------------------
This project contains the DUnit test framework and the GUI/Console test runners.
Add "CONSOLE_TESTRUNNER" to the conditional defines entry in the project options
to use the console test runner. Otherwise the GUI test runner will be used by
default.
}
{$IFDEF CONSOLE_TESTRUNNER}
{$APPTYPE CONSOLE}
{$ENDIF}
uses
DUnitTestRunner,
MVCFramework.Tests.RESTClient in 'MVCFramework.Tests.RESTClient.pas',
MVCFramework.Tests.AppController in 'MVCFramework.Tests.AppController.pas',
MVCFramework.Tests.WebModule in 'MVCFramework.Tests.WebModule.pas' {TestWebModule: TWebModule};
{ R *.RES }
begin
ReportMemoryLeaksOnShutdown := True;
DUnitTestRunner.RunRegisteredTests;
end.

View File

@ -0,0 +1,551 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{EA900FF3-71BB-4F0F-8525-AA920B2D2948}</ProjectGuid>
<ProjectVersion>18.1</ProjectVersion>
<FrameworkType>VCL</FrameworkType>
<Base>True</Base>
<Config Condition="'$(Config)'==''">Debug</Config>
<Platform Condition="'$(Platform)'==''">Win32</Platform>
<TargetedPlatforms>1</TargetedPlatforms>
<AppType>Console</AppType>
<MainSource>RESTClientTests.dpr</MainSource>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Base' or '$(Base)'!=''">
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Base)'=='true') or '$(Base_Win32)'!=''">
<Base_Win32>true</Base_Win32>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win64' and '$(Base)'=='true') or '$(Base_Win64)'!=''">
<Base_Win64>true</Base_Win64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Debug' or '$(Cfg_1)'!=''">
<Cfg_1>true</Cfg_1>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Cfg_1)'=='true') or '$(Cfg_1_Win32)'!=''">
<Cfg_1_Win32>true</Cfg_1_Win32>
<CfgParent>Cfg_1</CfgParent>
<Cfg_1>true</Cfg_1>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Release' or '$(Cfg_2)'!=''">
<Cfg_2>true</Cfg_2>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Base)'!=''">
<DCC_DcpOutput>.\$(Platform)\$(Config)\dcp</DCC_DcpOutput>
<VerInfo_Locale>1046</VerInfo_Locale>
<VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
<DCC_BplOutput>.\$(Platform)\$(Config)\pkg</DCC_BplOutput>
<SanitizedProjectName>RESTClientTests</SanitizedProjectName>
<DCC_Define>_CONSOLE_TESTRUNNER;$(DCC_Define)</DCC_Define>
<DCC_UnitSearchPath>$(BDS)\Source\DUnit\src;..\..\sources;..\..\lib\iocpdelphiframework\Base;..\..\lib\iocpdelphiframework\Core;..\..\lib\iocpdelphiframework\Extensions;..\..\lib\delphistompclient;..\..\lib\dmustache;$(DCC_UnitSearchPath)</DCC_UnitSearchPath>
<DCC_Namespace>System;Xml;Data;Datasnap;Web;Soap;Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;$(DCC_Namespace)</DCC_Namespace>
<DCC_DcuOutput>.\$(Platform)\$(Config)\dcu</DCC_DcuOutput>
<DCC_ExeOutput>.\$(Platform)\$(Config)</DCC_ExeOutput>
<DCC_E>false</DCC_E>
<DCC_N>false</DCC_N>
<DCC_S>false</DCC_S>
<DCC_F>false</DCC_F>
<DCC_K>false</DCC_K>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win32)'!=''">
<VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
<DCC_UsePackage>DBXSqliteDriver;RESTComponents;DataSnapServerMidas;DBXDb2Driver;DBXInterBaseDriver;vclactnband;vclFireDAC;emsclientfiredac;DataSnapFireDAC;tethering;svnui;FireDACADSDriver;DBXMSSQLDriver;DatasnapConnectorsFreePascal;FireDACMSSQLDriver;vcltouch;vcldb;bindcompfmx;Intraweb;svn;DBXOracleDriver;inetdb;FmxTeeUI;FireDACIBDriver;fmx;fmxdae;vclib;FireDACDBXDriver;dbexpress;IndyCore;vclx;dsnap;DataSnapCommon;emsclient;FireDACCommon;RESTBackendComponents;DataSnapConnectors;VCLRESTComponents;soapserver;vclie;bindengine;DBXMySQLDriver;CloudService;FireDACOracleDriver;FireDACMySQLDriver;DBXFirebirdDriver;FireDACCommonDriver;DataSnapClient;inet;bindcompdbx;IndyIPCommon;vcl;DBXSybaseASEDriver;IndyIPServer;IndySystem;FireDACDb2Driver;dsnapcon;FireDACMSAccDriver;FireDACInfxDriver;fmxFireDAC;vclimg;TeeDB;FireDAC;FireDACSqliteDriver;FireDACPgDriver;ibmonitor;FireDACASADriver;DBXOdbcDriver;FireDACTDataDriver;FMXTee;soaprtl;DbxCommonDriver;ibxpress;Tee;DataSnapServer;xmlrtl;DataSnapNativeClient;ibxbindings;fmxobj;FireDACDSDriver;soapmidas;rtl;vclwinx;DbxClientDriver;DBXSybaseASADriver;CustomIPTransport;vcldsnap;bindcomp;appanalytics;DBXInformixDriver;IndyIPClient;bindcompvcl;TeeUI;vclribbon;dbxcds;VclSmp;adortl;FireDACODBCDriver;DataSnapIndy10ServerTransport;DataSnapProviderClient;dsnapxml;dbrtl;FireDACMongoDBDriver;IndyProtocols;inetdbxpress;fmxase;$(DCC_UsePackage)</DCC_UsePackage>
<DCC_Namespace>Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace)</DCC_Namespace>
<VerInfo_Locale>1033</VerInfo_Locale>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win64)'!=''">
<DCC_UsePackage>DBXSqliteDriver;RESTComponents;DataSnapServerMidas;DBXDb2Driver;DBXInterBaseDriver;vclactnband;vclFireDAC;emsclientfiredac;DataSnapFireDAC;tethering;FireDACADSDriver;DBXMSSQLDriver;DatasnapConnectorsFreePascal;FireDACMSSQLDriver;vcltouch;vcldb;bindcompfmx;Intraweb;DBXOracleDriver;inetdb;FmxTeeUI;FireDACIBDriver;fmx;fmxdae;vclib;FireDACDBXDriver;dbexpress;IndyCore;vclx;dsnap;DataSnapCommon;emsclient;FireDACCommon;RESTBackendComponents;DataSnapConnectors;VCLRESTComponents;soapserver;vclie;bindengine;DBXMySQLDriver;CloudService;FireDACOracleDriver;FireDACMySQLDriver;DBXFirebirdDriver;FireDACCommonDriver;DataSnapClient;inet;bindcompdbx;IndyIPCommon;vcl;DBXSybaseASEDriver;IndyIPServer;IndySystem;FireDACDb2Driver;dsnapcon;FireDACMSAccDriver;FireDACInfxDriver;fmxFireDAC;vclimg;TeeDB;FireDAC;FireDACSqliteDriver;FireDACPgDriver;ibmonitor;FireDACASADriver;DBXOdbcDriver;FireDACTDataDriver;FMXTee;soaprtl;DbxCommonDriver;ibxpress;Tee;DataSnapServer;xmlrtl;DataSnapNativeClient;ibxbindings;fmxobj;FireDACDSDriver;soapmidas;rtl;vclwinx;DbxClientDriver;DBXSybaseASADriver;CustomIPTransport;vcldsnap;bindcomp;appanalytics;DBXInformixDriver;IndyIPClient;bindcompvcl;TeeUI;vclribbon;dbxcds;VclSmp;adortl;FireDACODBCDriver;DataSnapIndy10ServerTransport;DataSnapProviderClient;dsnapxml;dbrtl;FireDACMongoDBDriver;IndyProtocols;inetdbxpress;fmxase;$(DCC_UsePackage)</DCC_UsePackage>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_1)'!=''">
<DCC_Define>DEBUG;$(DCC_Define)</DCC_Define>
<DCC_DebugDCUs>true</DCC_DebugDCUs>
<DCC_Optimize>false</DCC_Optimize>
<DCC_GenerateStackFrames>true</DCC_GenerateStackFrames>
<DCC_DebugInfoInExe>true</DCC_DebugInfoInExe>
<DCC_RemoteDebug>true</DCC_RemoteDebug>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_1_Win32)'!=''">
<Manifest_File>None</Manifest_File>
<VerInfo_Locale>1033</VerInfo_Locale>
<DCC_RemoteDebug>false</DCC_RemoteDebug>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2)'!=''">
<DCC_LocalDebugSymbols>false</DCC_LocalDebugSymbols>
<DCC_Define>RELEASE;$(DCC_Define)</DCC_Define>
<DCC_SymbolReferenceInfo>0</DCC_SymbolReferenceInfo>
<DCC_DebugInformation>0</DCC_DebugInformation>
</PropertyGroup>
<ItemGroup>
<DelphiCompile Include="$(MainSource)">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="MVCFramework.Tests.RESTClient.pas"/>
<DCCReference Include="MVCFramework.Tests.AppController.pas"/>
<DCCReference Include="MVCFramework.Tests.WebModule.pas">
<Form>TestWebModule</Form>
<FormType>dfm</FormType>
<DesignClass>TWebModule</DesignClass>
</DCCReference>
<BuildConfiguration Include="Release">
<Key>Cfg_2</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
<BuildConfiguration Include="Base">
<Key>Base</Key>
</BuildConfiguration>
<BuildConfiguration Include="Debug">
<Key>Cfg_1</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
</ItemGroup>
<ProjectExtensions>
<Borland.Personality>Delphi.Personality.12</Borland.Personality>
<Borland.ProjectType>Application</Borland.ProjectType>
<BorlandProject>
<Delphi.Personality>
<Source>
<Source Name="MainSource">RESTClientTests.dpr</Source>
</Source>
<Excluded_Packages>
<Excluded_Packages Name="$(BDSBIN)\dcloffice2k230.bpl">Microsoft Office 2000 Sample Automation Server Wrapper Components</Excluded_Packages>
<Excluded_Packages Name="$(BDSBIN)\dclofficexp230.bpl">Microsoft Office XP Sample Automation Server Wrapper Components</Excluded_Packages>
</Excluded_Packages>
</Delphi.Personality>
<Deployment Version="2">
<DeployFile LocalName="$(BDS)\Redist\osx32\libcgunwind.1.0.dylib" Class="DependencyModule">
<Platform Name="OSX32">
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployFile LocalName="$(BDS)\Redist\iossimulator\libcgunwind.1.0.dylib" Class="DependencyModule">
<Platform Name="iOSSimulator">
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployFile LocalName="$(BDS)\Redist\iossimulator\libPCRE.dylib" Class="DependencyModule">
<Platform Name="iOSSimulator">
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployFile LocalName="Win32\Debug\RESTClientTests.exe" Configuration="Debug" Class="ProjectOutput">
<Platform Name="Win32">
<RemoteName>RESTClientTests.exe</RemoteName>
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployClass Name="DependencyModule">
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.dll;.bpl</Extensions>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOSXResource">
<Platform Name="OSX32">
<RemoteDir>Contents\Resources</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidClassesDexFile">
<Platform Name="Android">
<RemoteDir>classes</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AdditionalDebugSymbols">
<Platform Name="Win32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>0</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch768">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon144">
<Platform Name="Android">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeMipsFile">
<Platform Name="Android">
<RemoteDir>library\lib\mips</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Required="true" Name="ProjectOutput">
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DependencyFramework">
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
<Extensions>.framework</Extensions>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch640">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch1024">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSDeviceDebug">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<RemoteDir>..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeX86File">
<Platform Name="Android">
<RemoteDir>library\lib\x86</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch320">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSInfoPList">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeArmeabiFile">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DebugSymbols">
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch1536">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage470">
<Platform Name="Android">
<RemoteDir>res\drawable-normal</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon96">
<Platform Name="Android">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage640">
<Platform Name="Android">
<RemoteDir>res\drawable-large</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch640x1136">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSEntitlements">
<Platform Name="iOSDevice64">
<RemoteDir>../</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<RemoteDir>../</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon72">
<Platform Name="Android">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidGDBServer">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOSXInfoPList">
<Platform Name="OSX32">
<RemoteDir>Contents</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOSXEntitlements">
<Platform Name="OSX32">
<RemoteDir>../</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch2048">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashStyles">
<Platform Name="Android">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage426">
<Platform Name="Android">
<RemoteDir>res\drawable-small</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashImageDef">
<Platform Name="Android">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSResource">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectAndroidManifest">
<Platform Name="Android">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_DefaultAppIcon">
<Platform Name="Android">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="File">
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>0</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\Resources\StartUp\</RemoteDir>
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>0</Operation>
</Platform>
<Platform Name="Android">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidServiceOutput">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Required="true" Name="DependencyPackage">
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.bpl</Extensions>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon48">
<Platform Name="Android">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage960">
<Platform Name="Android">
<RemoteDir>res\drawable-xlarge</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon36">
<Platform Name="Android">
<RemoteDir>res\drawable-ldpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSDeviceResourceRules">
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<ProjectRoot Platform="iOSDevice64" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Win64" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="iOSDevice32" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Win32" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="OSX32" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Android" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="iOSSimulator" Name="$(PROJECTNAME).app"/>
</Deployment>
<Platforms>
<Platform value="Win32">True</Platform>
<Platform value="Win64">False</Platform>
</Platforms>
<UnitTesting>
<TestFramework>DUnit / Delphi Win32</TestFramework>
<TestRunner>GUI</TestRunner>
<TestProjectName/>
<SourceProjectName/>
</UnitTesting>
</BorlandProject>
<ProjectFileVersion>12</ProjectFileVersion>
</ProjectExtensions>
<Import Project="$(BDS)\Bin\CodeGear.Delphi.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Delphi.Targets')"/>
<Import Project="$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj" Condition="Exists('$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj')"/>
<Import Project="$(MSBuildProjectName).deployproj" Condition="Exists('$(MSBuildProjectName).deployproj')"/>
</Project>

Binary file not shown.

View File

@ -1,424 +1,424 @@
unit BOs;
interface
uses
FrameworkTestsU, system.TimeSpan, system.SysUtils, generics.collections,
ObjectsMappers, system.Classes;
type
TMyObject = class
private
FPropString: string;
FPropAnsiString: AnsiString;
FPropInt64: Int64;
FPropUInt32: cardinal;
FPropUInt64: UInt64;
FPropUInt16: word;
FPropInt16: smallint;
FPropBoolean: boolean;
FPropDateTime: TDateTime;
FPropDate: TDate;
FPropInteger: Integer;
FPropTimeStamp: TTimeStamp;
FPropTime: TTime;
FPropCurrency: Currency;
procedure SetPropAnsiString(const Value: AnsiString);
procedure SetPropString(const Value: string);
procedure SetPropInt64(const Value: Int64);
procedure SetPropUInt32(const Value: cardinal);
procedure SetPropUInt64(const Value: UInt64);
procedure SetPropInt16(const Value: smallint);
procedure SetPropUInt16(const Value: word);
procedure SetPropBoolean(const Value: boolean);
procedure SetPropDate(const Value: TDate);
procedure SetPropDateTime(const Value: TDateTime);
procedure SetPropInteger(const Value: Integer);
procedure SetPropTimeStamp(const Value: TTimeStamp);
procedure SetPropTime(const Value: TTime);
procedure SetPropCurrency(const Value: Currency);
public
function Equals(Obj: TMyObject): boolean; reintroduce;
property PropString: string read FPropString write SetPropString;
property PropAnsiString: AnsiString read FPropAnsiString write SetPropAnsiString;
property PropInteger: Integer read FPropInteger write SetPropInteger;
property PropUInt32: cardinal read FPropUInt32 write SetPropUInt32;
property PropInt64: Int64 read FPropInt64 write SetPropInt64;
property PropUInt64: UInt64 read FPropUInt64 write SetPropUInt64;
property PropUInt16: word read FPropUInt16 write SetPropUInt16;
property PropInt16: smallint read FPropInt16 write SetPropInt16;
property PropBoolean: boolean read FPropBoolean write SetPropBoolean;
property PropDate: TDate read FPropDate write SetPropDate;
property PropTime: TTime read FPropTime write SetPropTime;
property PropDateTime: TDateTime read FPropDateTime write SetPropDateTime;
property PropTimeStamp: TTimeStamp read FPropTimeStamp write SetPropTimeStamp;
property PropCurrency: Currency read FPropCurrency write SetPropCurrency;
end;
TMyChildObject = class
private
FMyChildProperty1: string;
procedure SetMyChildProperty1(const Value: string);
public
constructor Create;
property MyChildProperty1: string read FMyChildProperty1 write SetMyChildProperty1;
end;
[MapperListOf(TMyChildObject)]
TMyChildObjectList = class(TObjectList<TMyChildObject>)
end;
TMyComplexObject = class
private
FProp1: string;
FChildObjectList: TMyChildObjectList;
FChildObject: TMyChildObject;
procedure SetChildObject(const Value: TMyChildObject);
procedure SetChildObjectList(const Value: TMyChildObjectList);
procedure SetProp1(const Value: string);
public
constructor Create;
destructor Destroy; override;
function Equals(Obj: TObject): boolean; override;
property Prop1: string read FProp1 write SetProp1;
property ChildObject: TMyChildObject read FChildObject write SetChildObject;
property ChildObjectList: TMyChildObjectList read FChildObjectList write SetChildObjectList;
end;
TMyStreamObject = class(TObject)
private
FPropStream: TStream;
FProp8Stream: TStream;
procedure SetPropStream(const Value: TStream);
procedure SetProp8Stream(const Value: TStream);
public
constructor Create;
destructor Destroy; override;
[MapperSerializeAsString('utf-16')]
property PropStream: TStream read FPropStream write SetPropStream;
[MapperSerializeAsString]
// utf-8 is default
property Prop8Stream: TStream read FProp8Stream write SetProp8Stream;
end;
TMyObjectWithLogic = class
private
FLastName: string;
FFirstName: string;
FAge: Integer;
function GetFullName: string;
procedure SetFirstName(const Value: string);
procedure SetLastName(const Value: string);
function GetIsAdult: boolean;
procedure SetAge(const Value: Integer);
public
constructor Create(aFirstName, aLastName: string; aAge: Integer);
function Equals(Obj: TObject): boolean; override;
property FirstName: string read FFirstName write SetFirstName;
property LastName: string read FLastName write SetLastName;
property Age: Integer read FAge write SetAge;
property IsAdult: boolean read GetIsAdult;
property FullName: string read GetFullName;
end;
function GetMyObject: TMyObject;
function GetMyComplexObject: TMyComplexObject;
function GetMyComplexObjectWithNotInitializedChilds: TMyComplexObject;
implementation
uses
system.DateUtils;
function GetMyComplexObjectWithNotInitializedChilds: TMyComplexObject;
var
co: TMyChildObject;
begin
Result := TMyComplexObject.Create;
Result.Prop1 := 'property1';
end;
function GetMyComplexObject: TMyComplexObject;
var
co: TMyChildObject;
begin
Result := TMyComplexObject.Create;
Result.Prop1 := 'property1';
Result.ChildObject.MyChildProperty1 := 'MySingleChildProperty1';
co := TMyChildObject.Create;
co.MyChildProperty1 := 'MyChildProperty1';
Result.ChildObjectList.Add(co);
co := TMyChildObject.Create;
co.MyChildProperty1 := 'MyChildProperty2';
Result.ChildObjectList.Add(co);
co := TMyChildObject.Create;
co.MyChildProperty1 := 'MyChildProperty3';
Result.ChildObjectList.Add(co);
co := TMyChildObject.Create;
co.MyChildProperty1 := 'MyChildProperty4';
Result.ChildObjectList.Add(co);
end;
function GetMyObject: TMyObject;
begin
Result := TMyObject.Create;
Result.PropString := 'Some text àèéìòù';
Result.PropAnsiString := 'This is an ANSI text';
Result.PropInteger := - 1234;
Result.PropUInt32 := 1234;
Result.PropInt64 := - 1234567890;
Result.PropUInt64 := 1234567890;
Result.PropUInt16 := 12345;
Result.PropInt16 := - 12345;
Result.PropCurrency := 1234.5678;
Result.PropBoolean := true;
Result.PropDate := EncodeDate(2010, 10, 20);
Result.PropTime := EncodeTime(10, 20, 30, 40);
Result.PropDateTime := Result.PropDate + Result.PropTime;
Result.PropTimeStamp := DateTimeToTimeStamp(Result.PropDateTime + 1);
end;
function TMyObject.Equals(Obj: TMyObject): boolean;
begin
Result := true;
Result := Result and (Self.PropString = Obj.PropString);
Result := Result and (Self.PropAnsiString = Obj.PropAnsiString);
Result := Result and (Self.PropInteger = Obj.PropInteger);
Result := Result and (Self.PropUInt32 = Obj.PropUInt32);
Result := Result and (Self.PropInt64 = Obj.PropInt64);
Result := Result and (Self.PropUInt64 = Obj.PropUInt64);
Result := Result and (Self.PropUInt16 = Obj.PropUInt16);
Result := Result and (Self.PropInt16 = Obj.PropInt16);
Result := Result and (Self.PropBoolean = Obj.PropBoolean);
Result := Result and (Self.PropDate = Obj.PropDate);
Result := Result and (Self.PropCurrency = Obj.PropCurrency);
Result := Result and (SecondsBetween(Self.PropTime, Obj.PropTime) = 0);
Result := Result and (SecondsBetween(Self.PropDateTime, Obj.PropDateTime) = 0);
Result := Result and (Self.PropTimeStamp.Date = Obj.PropTimeStamp.Date) and
(Self.PropTimeStamp.Time = Obj.PropTimeStamp.Time);
end;
procedure TMyObject.SetPropAnsiString(const Value: AnsiString);
begin
FPropAnsiString := Value;
end;
procedure TMyObject.SetPropBoolean(const Value: boolean);
begin
FPropBoolean := Value;
end;
procedure TMyObject.SetPropCurrency(const Value: Currency);
begin
FPropCurrency := Value;
end;
procedure TMyObject.SetPropDate(const Value: TDate);
begin
FPropDate := Value;
end;
procedure TMyObject.SetPropDateTime(const Value: TDateTime);
begin
FPropDateTime := Value;
end;
procedure TMyObject.SetPropInt16(const Value: smallint);
begin
FPropInt16 := Value;
end;
procedure TMyObject.SetPropInt64(const Value: Int64);
begin
FPropInt64 := Value;
end;
procedure TMyObject.SetPropInteger(const Value: Integer);
begin
FPropInteger := Value;
end;
procedure TMyObject.SetPropString(const Value: string);
begin
FPropString := Value;
end;
procedure TMyObject.SetPropTime(const Value: TTime);
begin
FPropTime := Value;
end;
procedure TMyObject.SetPropTimeStamp(const Value: TTimeStamp);
begin
FPropTimeStamp := Value;
end;
procedure TMyObject.SetPropUInt16(const Value: word);
begin
FPropUInt16 := Value;
end;
procedure TMyObject.SetPropUInt32(const Value: cardinal);
begin
FPropUInt32 := Value;
end;
procedure TMyObject.SetPropUInt64(const Value: UInt64);
begin
FPropUInt64 := Value;
end;
{ TMyComplexObject }
constructor TMyComplexObject.Create;
begin
inherited;
FChildObjectList := TMyChildObjectList.Create(true);
FChildObject := TMyChildObject.Create;
end;
destructor TMyComplexObject.Destroy;
begin
FChildObjectList.Free;
FChildObject.Free;
inherited;
end;
function TMyComplexObject.Equals(Obj: TObject): boolean;
var
co: TMyComplexObject;
begin
co := Obj as TMyComplexObject;
Result := co.Prop1 = Self.Prop1;
if Assigned(co.ChildObject) and Assigned(Self.ChildObject) then
Result := Result and (co.ChildObject.MyChildProperty1 = Self.ChildObject.MyChildProperty1)
else
Result := Result and (not Assigned(co.ChildObject)) and (not Assigned(Self.ChildObject));
Result := Result and (co.ChildObjectList.Count = Self.ChildObjectList.Count);
if co.ChildObjectList.Count = 0 then
Exit;
Result := Result and (co.ChildObjectList[0].MyChildProperty1 = Self.ChildObjectList[0]
.MyChildProperty1);
Result := Result and (co.ChildObjectList[1].MyChildProperty1 = Self.ChildObjectList[1]
.MyChildProperty1);
Result := Result and (co.ChildObjectList[2].MyChildProperty1 = Self.ChildObjectList[2]
.MyChildProperty1);
Result := Result and (co.ChildObjectList[3].MyChildProperty1 = Self.ChildObjectList[3]
.MyChildProperty1);
end;
procedure TMyComplexObject.SetChildObject(const Value: TMyChildObject);
begin
FChildObject := Value;
end;
procedure TMyComplexObject.SetChildObjectList(const Value: TMyChildObjectList);
begin
FChildObjectList := Value;
end;
procedure TMyComplexObject.SetProp1(const Value: string);
begin
FProp1 := Value;
end;
{ TMyChildObject }
constructor TMyChildObject.Create;
begin
inherited;
Self.MyChildProperty1 := 'my default value';
end;
procedure TMyChildObject.SetMyChildProperty1(const Value: string);
begin
FMyChildProperty1 := Value;
end;
{ TMyStreamObject }
constructor TMyStreamObject.Create;
begin
inherited Create;
FPropStream := TStringStream.Create('', TEncoding.Unicode);
FProp8Stream := TStringStream.Create('', TEncoding.UTF8);
end;
destructor TMyStreamObject.Destroy;
begin
if Assigned(FPropStream) then
FPropStream.Free;
if Assigned(FProp8Stream) then
FProp8Stream.Free;
inherited;
end;
procedure TMyStreamObject.SetProp8Stream(const Value: TStream);
begin
if Assigned(FProp8Stream) then
FProp8Stream.Free;
FProp8Stream := Value;
end;
procedure TMyStreamObject.SetPropStream(const Value: TStream);
begin
if Assigned(FPropStream) then
FPropStream.Free;
FPropStream := Value;
end;
{ TCliente }
{ TMyObjectWithLogic }
constructor TMyObjectWithLogic.Create(aFirstName, aLastName: string; aAge: Integer);
begin
inherited Create;
FFirstName := aFirstName;
FLastName := aLastName;
FAge := aAge;
end;
function TMyObjectWithLogic.Equals(Obj: TObject): boolean;
var
lOther: TMyObjectWithLogic;
begin
Result := (Obj is TMyObjectWithLogic);
if Result then
begin
lOther := TMyObjectWithLogic(Obj);
Result := Result and (Self.FirstName = lOther.FirstName);
Result := Result and (Self.LastName = lOther.LastName);
Result := Result and (Self.Age = lOther.Age);
end;
end;
function TMyObjectWithLogic.GetFullName: string;
begin
Result := FirstName + ' ' + LastName; // logic
end;
function TMyObjectWithLogic.GetIsAdult: boolean;
begin
Result := Age >= 18; // logic
end;
procedure TMyObjectWithLogic.SetAge(const Value: Integer);
begin
FAge := Value;
end;
procedure TMyObjectWithLogic.SetFirstName(const Value: string);
begin
FFirstName := Value;
end;
procedure TMyObjectWithLogic.SetLastName(const Value: string);
begin
FLastName := Value;
end;
end.
unit BOs;
interface
uses
FrameworkTestsU, system.TimeSpan, system.SysUtils, generics.collections,
ObjectsMappers, system.Classes;
type
TMyObject = class
private
FPropString: string;
FPropAnsiString: AnsiString;
FPropInt64: Int64;
FPropUInt32: cardinal;
FPropUInt64: UInt64;
FPropUInt16: word;
FPropInt16: smallint;
FPropBoolean: boolean;
FPropDateTime: TDateTime;
FPropDate: TDate;
FPropInteger: Integer;
FPropTimeStamp: TTimeStamp;
FPropTime: TTime;
FPropCurrency: Currency;
procedure SetPropAnsiString(const Value: AnsiString);
procedure SetPropString(const Value: string);
procedure SetPropInt64(const Value: Int64);
procedure SetPropUInt32(const Value: cardinal);
procedure SetPropUInt64(const Value: UInt64);
procedure SetPropInt16(const Value: smallint);
procedure SetPropUInt16(const Value: word);
procedure SetPropBoolean(const Value: boolean);
procedure SetPropDate(const Value: TDate);
procedure SetPropDateTime(const Value: TDateTime);
procedure SetPropInteger(const Value: Integer);
procedure SetPropTimeStamp(const Value: TTimeStamp);
procedure SetPropTime(const Value: TTime);
procedure SetPropCurrency(const Value: Currency);
public
function Equals(Obj: TMyObject): boolean; reintroduce;
property PropString: string read FPropString write SetPropString;
property PropAnsiString: AnsiString read FPropAnsiString write SetPropAnsiString;
property PropInteger: Integer read FPropInteger write SetPropInteger;
property PropUInt32: cardinal read FPropUInt32 write SetPropUInt32;
property PropInt64: Int64 read FPropInt64 write SetPropInt64;
property PropUInt64: UInt64 read FPropUInt64 write SetPropUInt64;
property PropUInt16: word read FPropUInt16 write SetPropUInt16;
property PropInt16: smallint read FPropInt16 write SetPropInt16;
property PropBoolean: boolean read FPropBoolean write SetPropBoolean;
property PropDate: TDate read FPropDate write SetPropDate;
property PropTime: TTime read FPropTime write SetPropTime;
property PropDateTime: TDateTime read FPropDateTime write SetPropDateTime;
property PropTimeStamp: TTimeStamp read FPropTimeStamp write SetPropTimeStamp;
property PropCurrency: Currency read FPropCurrency write SetPropCurrency;
end;
TMyChildObject = class
private
FMyChildProperty1: string;
procedure SetMyChildProperty1(const Value: string);
public
constructor Create;
property MyChildProperty1: string read FMyChildProperty1 write SetMyChildProperty1;
end;
[MapperListOf(TMyChildObject)]
TMyChildObjectList = class(TObjectList<TMyChildObject>)
end;
TMyComplexObject = class
private
FProp1: string;
FChildObjectList: TMyChildObjectList;
FChildObject: TMyChildObject;
procedure SetChildObject(const Value: TMyChildObject);
procedure SetChildObjectList(const Value: TMyChildObjectList);
procedure SetProp1(const Value: string);
public
constructor Create;
destructor Destroy; override;
function Equals(Obj: TObject): boolean; override;
property Prop1: string read FProp1 write SetProp1;
property ChildObject: TMyChildObject read FChildObject write SetChildObject;
property ChildObjectList: TMyChildObjectList read FChildObjectList write SetChildObjectList;
end;
TMyStreamObject = class(TObject)
private
FPropStream: TStream;
FProp8Stream: TStream;
procedure SetPropStream(const Value: TStream);
procedure SetProp8Stream(const Value: TStream);
public
constructor Create;
destructor Destroy; override;
[MapperSerializeAsString('utf-16')]
property PropStream: TStream read FPropStream write SetPropStream;
[MapperSerializeAsString]
// utf-8 is default
property Prop8Stream: TStream read FProp8Stream write SetProp8Stream;
end;
TMyObjectWithLogic = class
private
FLastName: string;
FFirstName: string;
FAge: Integer;
function GetFullName: string;
procedure SetFirstName(const Value: string);
procedure SetLastName(const Value: string);
function GetIsAdult: boolean;
procedure SetAge(const Value: Integer);
public
constructor Create(aFirstName, aLastName: string; aAge: Integer);
function Equals(Obj: TObject): boolean; override;
property FirstName: string read FFirstName write SetFirstName;
property LastName: string read FLastName write SetLastName;
property Age: Integer read FAge write SetAge;
property IsAdult: boolean read GetIsAdult;
property FullName: string read GetFullName;
end;
function GetMyObject: TMyObject;
function GetMyComplexObject: TMyComplexObject;
function GetMyComplexObjectWithNotInitializedChilds: TMyComplexObject;
implementation
uses
system.DateUtils;
function GetMyComplexObjectWithNotInitializedChilds: TMyComplexObject;
var
co: TMyChildObject;
begin
Result := TMyComplexObject.Create;
Result.Prop1 := 'property1';
end;
function GetMyComplexObject: TMyComplexObject;
var
co: TMyChildObject;
begin
Result := TMyComplexObject.Create;
Result.Prop1 := 'property1';
Result.ChildObject.MyChildProperty1 := 'MySingleChildProperty1';
co := TMyChildObject.Create;
co.MyChildProperty1 := 'MyChildProperty1';
Result.ChildObjectList.Add(co);
co := TMyChildObject.Create;
co.MyChildProperty1 := 'MyChildProperty2';
Result.ChildObjectList.Add(co);
co := TMyChildObject.Create;
co.MyChildProperty1 := 'MyChildProperty3';
Result.ChildObjectList.Add(co);
co := TMyChildObject.Create;
co.MyChildProperty1 := 'MyChildProperty4';
Result.ChildObjectList.Add(co);
end;
function GetMyObject: TMyObject;
begin
Result := TMyObject.Create;
Result.PropString := 'Some text àèéìòù';
Result.PropAnsiString := 'This is an ANSI text';
Result.PropInteger := - 1234;
Result.PropUInt32 := 1234;
Result.PropInt64 := - 1234567890;
Result.PropUInt64 := 1234567890;
Result.PropUInt16 := 12345;
Result.PropInt16 := - 12345;
Result.PropCurrency := 1234.5678;
Result.PropBoolean := true;
Result.PropDate := EncodeDate(2010, 10, 20);
Result.PropTime := EncodeTime(10, 20, 30, 40);
Result.PropDateTime := Result.PropDate + Result.PropTime;
Result.PropTimeStamp := DateTimeToTimeStamp(Result.PropDateTime + 1);
end;
function TMyObject.Equals(Obj: TMyObject): boolean;
begin
Result := true;
Result := Result and (Self.PropString = Obj.PropString);
Result := Result and (Self.PropAnsiString = Obj.PropAnsiString);
Result := Result and (Self.PropInteger = Obj.PropInteger);
Result := Result and (Self.PropUInt32 = Obj.PropUInt32);
Result := Result and (Self.PropInt64 = Obj.PropInt64);
Result := Result and (Self.PropUInt64 = Obj.PropUInt64);
Result := Result and (Self.PropUInt16 = Obj.PropUInt16);
Result := Result and (Self.PropInt16 = Obj.PropInt16);
Result := Result and (Self.PropBoolean = Obj.PropBoolean);
Result := Result and (Self.PropDate = Obj.PropDate);
Result := Result and (Self.PropCurrency = Obj.PropCurrency);
Result := Result and (SecondsBetween(Self.PropTime, Obj.PropTime) = 0);
Result := Result and (SecondsBetween(Self.PropDateTime, Obj.PropDateTime) = 0);
Result := Result and (Self.PropTimeStamp.Date = Obj.PropTimeStamp.Date) and
(Self.PropTimeStamp.Time = Obj.PropTimeStamp.Time);
end;
procedure TMyObject.SetPropAnsiString(const Value: AnsiString);
begin
FPropAnsiString := Value;
end;
procedure TMyObject.SetPropBoolean(const Value: boolean);
begin
FPropBoolean := Value;
end;
procedure TMyObject.SetPropCurrency(const Value: Currency);
begin
FPropCurrency := Value;
end;
procedure TMyObject.SetPropDate(const Value: TDate);
begin
FPropDate := Value;
end;
procedure TMyObject.SetPropDateTime(const Value: TDateTime);
begin
FPropDateTime := Value;
end;
procedure TMyObject.SetPropInt16(const Value: smallint);
begin
FPropInt16 := Value;
end;
procedure TMyObject.SetPropInt64(const Value: Int64);
begin
FPropInt64 := Value;
end;
procedure TMyObject.SetPropInteger(const Value: Integer);
begin
FPropInteger := Value;
end;
procedure TMyObject.SetPropString(const Value: string);
begin
FPropString := Value;
end;
procedure TMyObject.SetPropTime(const Value: TTime);
begin
FPropTime := Value;
end;
procedure TMyObject.SetPropTimeStamp(const Value: TTimeStamp);
begin
FPropTimeStamp := Value;
end;
procedure TMyObject.SetPropUInt16(const Value: word);
begin
FPropUInt16 := Value;
end;
procedure TMyObject.SetPropUInt32(const Value: cardinal);
begin
FPropUInt32 := Value;
end;
procedure TMyObject.SetPropUInt64(const Value: UInt64);
begin
FPropUInt64 := Value;
end;
{ TMyComplexObject }
constructor TMyComplexObject.Create;
begin
inherited;
FChildObjectList := TMyChildObjectList.Create(true);
FChildObject := TMyChildObject.Create;
end;
destructor TMyComplexObject.Destroy;
begin
FChildObjectList.Free;
FChildObject.Free;
inherited;
end;
function TMyComplexObject.Equals(Obj: TObject): boolean;
var
co: TMyComplexObject;
begin
co := Obj as TMyComplexObject;
Result := co.Prop1 = Self.Prop1;
if Assigned(co.ChildObject) and Assigned(Self.ChildObject) then
Result := Result and (co.ChildObject.MyChildProperty1 = Self.ChildObject.MyChildProperty1)
else
Result := Result and (not Assigned(co.ChildObject)) and (not Assigned(Self.ChildObject));
Result := Result and (co.ChildObjectList.Count = Self.ChildObjectList.Count);
if co.ChildObjectList.Count = 0 then
Exit;
Result := Result and (co.ChildObjectList[0].MyChildProperty1 = Self.ChildObjectList[0]
.MyChildProperty1);
Result := Result and (co.ChildObjectList[1].MyChildProperty1 = Self.ChildObjectList[1]
.MyChildProperty1);
Result := Result and (co.ChildObjectList[2].MyChildProperty1 = Self.ChildObjectList[2]
.MyChildProperty1);
Result := Result and (co.ChildObjectList[3].MyChildProperty1 = Self.ChildObjectList[3]
.MyChildProperty1);
end;
procedure TMyComplexObject.SetChildObject(const Value: TMyChildObject);
begin
FChildObject := Value;
end;
procedure TMyComplexObject.SetChildObjectList(const Value: TMyChildObjectList);
begin
FChildObjectList := Value;
end;
procedure TMyComplexObject.SetProp1(const Value: string);
begin
FProp1 := Value;
end;
{ TMyChildObject }
constructor TMyChildObject.Create;
begin
inherited;
Self.MyChildProperty1 := 'my default value';
end;
procedure TMyChildObject.SetMyChildProperty1(const Value: string);
begin
FMyChildProperty1 := Value;
end;
{ TMyStreamObject }
constructor TMyStreamObject.Create;
begin
inherited Create;
FPropStream := TStringStream.Create('', TEncoding.Unicode);
FProp8Stream := TStringStream.Create('', TEncoding.UTF8);
end;
destructor TMyStreamObject.Destroy;
begin
if Assigned(FPropStream) then
FPropStream.Free;
if Assigned(FProp8Stream) then
FProp8Stream.Free;
inherited;
end;
procedure TMyStreamObject.SetProp8Stream(const Value: TStream);
begin
if Assigned(FProp8Stream) then
FProp8Stream.Free;
FProp8Stream := Value;
end;
procedure TMyStreamObject.SetPropStream(const Value: TStream);
begin
if Assigned(FPropStream) then
FPropStream.Free;
FPropStream := Value;
end;
{ TCliente }
{ TMyObjectWithLogic }
constructor TMyObjectWithLogic.Create(aFirstName, aLastName: string; aAge: Integer);
begin
inherited Create;
FFirstName := aFirstName;
FLastName := aLastName;
FAge := aAge;
end;
function TMyObjectWithLogic.Equals(Obj: TObject): boolean;
var
lOther: TMyObjectWithLogic;
begin
Result := (Obj is TMyObjectWithLogic);
if Result then
begin
lOther := TMyObjectWithLogic(Obj);
Result := Result and (Self.FirstName = lOther.FirstName);
Result := Result and (Self.LastName = lOther.LastName);
Result := Result and (Self.Age = lOther.Age);
end;
end;
function TMyObjectWithLogic.GetFullName: string;
begin
Result := FirstName + ' ' + LastName; // logic
end;
function TMyObjectWithLogic.GetIsAdult: boolean;
begin
Result := Age >= 18; // logic
end;
procedure TMyObjectWithLogic.SetAge(const Value: Integer);
begin
FAge := Value;
end;
procedure TMyObjectWithLogic.SetFirstName(const Value: string);
begin
FFirstName := Value;
end;
procedure TMyObjectWithLogic.SetLastName(const Value: string);
begin
FLastName := Value;
end;
end.

View File

@ -1,41 +1,35 @@
program DMVCFrameworkTests;
{
Delphi DUnit Test Project
-------------------------
This project contains the DUnit test framework and the GUI/Console test runners.
Add "CONSOLE_TESTRUNNER" to the conditional defines entry in the project options
to use the console test runner. Otherwise the GUI test runner will be used by
default.
}
{$IFDEF CONSOLE_TESTRUNNER}
{$APPTYPE CONSOLE}
{$ENDIF}
uses
DUnitTestRunner,
FrameworkTestsU in 'FrameworkTestsU.pas',
LiveServerTestU in 'LiveServerTestU.pas',
MessagingExtensionsTestU in 'MessagingExtensionsTestU.pas',
TestControllersU in 'TestControllersU.pas',
MVCFramework.RESTClient in '..\..\sources\MVCFramework.RESTClient.pas',
BusinessObjectsU in '..\..\samples\commons\BusinessObjectsU.pas',
ObjectsMappers in '..\..\sources\ObjectsMappers.pas',
BOs in 'BOs.pas',
RTTIUtilsU in '..\..\sources\RTTIUtilsU.pas',
TestServerControllerU in '..\TestServer\TestServerControllerU.pas',
RESTAdapterTestsU in 'RESTAdapterTestsU.pas',
MVCFramework.RESTAdapter in '..\..\sources\MVCFramework.RESTAdapter.pas',
MVCFramework.Server in '..\..\sources\MVCFramework.Server.pas',
MVCFrameworkServerTestsU in 'MVCFrameworkServerTestsU.pas',
TestWebModuleU in 'TestWebModuleU.pas' {TestWebModule: TWebModule};
{$R *.RES}
begin
ReportMemoryLeaksOnShutdown := true;
DUnitTestRunner.RunRegisteredTests;
end.
program DMVCFrameworkTests;
{
Delphi DUnit Test Project
-------------------------
This project contains the DUnit test framework and the GUI/Console test runners.
Add "CONSOLE_TESTRUNNER" to the conditional defines entry in the project options
to use the console test runner. Otherwise the GUI test runner will be used by
default.
}
{$IFDEF CONSOLE_TESTRUNNER}
{$APPTYPE CONSOLE}
{$ENDIF}
uses
DUnitTestRunner,
FrameworkTestsU in 'FrameworkTestsU.pas',
LiveServerTestU in 'LiveServerTestU.pas',
MessagingExtensionsTestU in 'MessagingExtensionsTestU.pas',
BusinessObjectsU in '..\..\samples\commons\BusinessObjectsU.pas',
BOs in 'BOs.pas',
TestServerControllerU in '..\TestServer\TestServerControllerU.pas',
RESTAdapterTestsU in 'RESTAdapterTestsU.pas';
{$R *.RES}
begin
ReportMemoryLeaksOnShutdown := True;
DUnitTestRunner.RunRegisteredTests;
end.

View File

@ -1,211 +1,211 @@
unit MessagingExtensionsTestU;
interface
uses
TestFramework,
MVCFramework.RESTClient,
LiveServerTestU;
type
TMessagingExtensionsTestCase = class(TBaseServerTest)
published
procedure TestSubscribeOnATopic;
procedure TestMultipleSubscribeOnSameTopic;
procedure TestMultipleSubscribeAndUnsubscribe;
procedure TestMultipleSubscribeAndUnsubscribeHARD;
procedure TestSubscribeAndReceive;
end;
implementation
{$WARN SYMBOL_DEPRECATED OFF}
uses
System.SysUtils,
{$IF CompilerVersion < 27}
Data.DBXJSON,
{$ELSE}
System.JSON,
{$ENDIF}
System.Classes,
MVCFramework.Logger, MVCFramework.Commons, Winapi.Windows;
{ TMessagingExtensionsTestCase }
procedure TMessagingExtensionsTestCase.TestMultipleSubscribeAndUnsubscribe;
var
res: IRESTResponse;
x: string;
begin
RESTClient.ReadTimeout := - 1;
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-id']);
res := RESTClient.doPOST('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals('/queue/test01', x);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test010']);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shoud not return an error
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals('/queue/test01;/queue/test010', x);
res := RESTClient.doDELETE('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shoud not return an error
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals('/queue/test010', x);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shod not return an error
DoLogout;
end;
procedure TMessagingExtensionsTestCase.TestMultipleSubscribeAndUnsubscribeHARD;
var
res: IRESTResponse;
x: string;
begin
RESTClient.ReadTimeout := - 1;
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-id']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test01']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test010']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test0101']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test01010']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test010101']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test0101010']);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shod not return an error
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals
('/queue/test01;/queue/test010;/queue/test0101;/queue/test01010;/queue/test010101;/queue/test0101010',
x);
res := RESTClient.doDELETE('/messages/subscriptions/queue', ['test010']);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shod not return an error
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals
('/queue/test01;/queue/test0101;/queue/test01010;/queue/test010101;/queue/test0101010', x);
DoLogout;
end;
procedure TMessagingExtensionsTestCase.TestMultipleSubscribeOnSameTopic;
var
res: IRESTResponse;
begin
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-id']);
res := RESTClient.doPOST('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
res := RESTClient.doPOST('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shoud not return an error
DoLogout;
end;
procedure TMessagingExtensionsTestCase.TestSubscribeAndReceive;
var
res: IRESTResponse;
messages: TJSONArray;
sid: string;
RMessageCount: Integer;
I: Integer;
o: TJSONObject;
J: Integer;
LUnique: string;
const
MSG_COUNT = 10;
begin
LUnique := GetTickCount.ToString;
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-' + LUnique]);
RESTClient.doPOST('/messages', ['subscriptions', 'queue', 'test01']);
RESTClient.doPOST('/messages', ['subscriptions', 'queue', 'test02']);
RESTClient.ReadTimeout := - 1;
sid := RESTClient.SessionID;
TThread.CreateAnonymousThread(
procedure
var
RESTC: TRESTClient;
I: Integer;
begin
TThread.Sleep(1000);
RESTC := TRESTClient.Create('localhost', 9999);
try
RESTC.doPOST('/messages/clients', ['my-other-unique-' + LUnique]);
RESTC.ReadTimeout := 60 * 1000 * 30;
RESTC.doGET('/login', ['guest']);
for I := 1 to MSG_COUNT do
begin
RESTC.doPOST('/messages/queue/test02', [], TJSONObject.Create(TJSONPair.Create('hello',
TJSONNumber.Create(I))));
RESTC.doPOST('/messages/queue/test01', [], TJSONObject.Create(TJSONPair.Create('hello',
TJSONNumber.Create(I))));
end;
finally
RESTC.Free;
end;
end).Start;
RMessageCount := 0;
for J := 1 to MSG_COUNT * 2 do
begin
res := RESTClient.doGET('/messages', []);
if res.ResponseCode = HTTP_STATUS.OK then
begin
CheckIs(res.BodyAsJsonObject.Get('_timeout').JsonValue, TJSONFalse);
CheckNotNull(res.BodyAsJsonObject.Get('_timestamp'), '_timestamp is not set');
CheckNotNull(res.BodyAsJsonObject.Get('messages'), 'messages is not set');
CheckIs(res.BodyAsJsonObject.Get('messages').JsonValue, TJSONArray,
'Messages is not a TJSONArray');
messages := res.BodyAsJsonObject.Get('messages').JsonValue as TJSONArray;
if messages.Size > 0 then
for I := 0 to messages.Size - 1 do
begin
o := messages.Get(I) as TJSONObject;
logw(o.Get('message').ToString);
end;
RMessageCount := RMessageCount + messages.Size;
end;
if res.ResponseCode = HTTP_STATUS.RequestTimeout then // receive timeout
break;
end;
CheckEquals(MSG_COUNT * 2, RMessageCount, 'message count');
res := RESTClient.doGET('/messages', []);
CheckIs(res.BodyAsJsonObject.Get('_timeout').JsonValue, TJSONTrue);
DoLogout;
end;
procedure TMessagingExtensionsTestCase.TestSubscribeOnATopic;
var
res: IRESTResponse;
begin
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-id']);
res := RESTClient.doPOST('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
res := RESTClient.doDELETE('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
DoLogout;
end;
initialization
{$IFDEF USE_MESSAGING}
RegisterTest(TMessagingExtensionsTestCase.Suite);
{$ENDIF}
finalization
end.
unit MessagingExtensionsTestU;
interface
uses
TestFramework,
MVCFramework.RESTClient,
LiveServerTestU;
type
TMessagingExtensionsTestCase = class(TBaseServerTest)
published
procedure TestSubscribeOnATopic;
procedure TestMultipleSubscribeOnSameTopic;
procedure TestMultipleSubscribeAndUnsubscribe;
procedure TestMultipleSubscribeAndUnsubscribeHARD;
procedure TestSubscribeAndReceive;
end;
implementation
{$WARN SYMBOL_DEPRECATED OFF}
uses
System.SysUtils,
{$IF CompilerVersion < 27}
Data.DBXJSON,
{$ELSE}
System.JSON,
{$ENDIF}
System.Classes,
MVCFramework.Logger, MVCFramework.Commons, Winapi.Windows;
{ TMessagingExtensionsTestCase }
procedure TMessagingExtensionsTestCase.TestMultipleSubscribeAndUnsubscribe;
var
res: IRESTResponse;
x: string;
begin
RESTClient.ReadTimeout(- 1);
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-id']);
res := RESTClient.doPOST('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals('/queue/test01', x);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test010']);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shoud not return an error
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals('/queue/test01;/queue/test010', x);
res := RESTClient.doDELETE('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shoud not return an error
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals('/queue/test010', x);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shod not return an error
DoLogout;
end;
procedure TMessagingExtensionsTestCase.TestMultipleSubscribeAndUnsubscribeHARD;
var
res: IRESTResponse;
x: string;
begin
RESTClient.ReadTimeout(-1);
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-id']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test01']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test010']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test0101']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test01010']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test010101']);
res := RESTClient.doPOST('/messages/subscriptions/queue', ['test0101010']);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shod not return an error
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals
('/queue/test01;/queue/test010;/queue/test0101;/queue/test01010;/queue/test010101;/queue/test0101010',
x);
res := RESTClient.doDELETE('/messages/subscriptions/queue', ['test010']);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shod not return an error
res := RESTClient.doGET('/messages/subscriptions', []);
x := Trim(res.BodyAsString);
CheckEquals
('/queue/test01;/queue/test0101;/queue/test01010;/queue/test010101;/queue/test0101010', x);
DoLogout;
end;
procedure TMessagingExtensionsTestCase.TestMultipleSubscribeOnSameTopic;
var
res: IRESTResponse;
begin
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-id']);
res := RESTClient.doPOST('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
res := RESTClient.doPOST('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
// server shoud not return an error
DoLogout;
end;
procedure TMessagingExtensionsTestCase.TestSubscribeAndReceive;
var
res: IRESTResponse;
messages: TJSONArray;
sid: string;
RMessageCount: Integer;
I: Integer;
o: TJSONObject;
J: Integer;
LUnique: string;
const
MSG_COUNT = 10;
begin
LUnique := GetTickCount.ToString;
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-' + LUnique]);
RESTClient.doPOST('/messages', ['subscriptions', 'queue', 'test01']);
RESTClient.doPOST('/messages', ['subscriptions', 'queue', 'test02']);
RESTClient.ReadTimeout(- 1);
sid := RESTClient.SessionID;
TThread.CreateAnonymousThread(
procedure
var
RESTC: TRESTClient;
I: Integer;
begin
TThread.Sleep(1000);
RESTC := TRESTClient.Create('localhost', 9999);
try
RESTC.doPOST('/messages/clients', ['my-other-unique-' + LUnique]);
RESTC.ReadTimeout(60 * 1000 * 30);
RESTC.doGET('/login', ['guest']);
for I := 1 to MSG_COUNT do
begin
RESTC.doPOST('/messages/queue/test02', [], TJSONObject.Create(TJSONPair.Create('hello',
TJSONNumber.Create(I))));
RESTC.doPOST('/messages/queue/test01', [], TJSONObject.Create(TJSONPair.Create('hello',
TJSONNumber.Create(I))));
end;
finally
RESTC.Free;
end;
end).Start;
RMessageCount := 0;
for J := 1 to MSG_COUNT * 2 do
begin
res := RESTClient.doGET('/messages', []);
if res.ResponseCode = HTTP_STATUS.OK then
begin
CheckIs(res.BodyAsJsonObject.Get('_timeout').JsonValue, TJSONFalse);
CheckNotNull(res.BodyAsJsonObject.Get('_timestamp'), '_timestamp is not set');
CheckNotNull(res.BodyAsJsonObject.Get('messages'), 'messages is not set');
CheckIs(res.BodyAsJsonObject.Get('messages').JsonValue, TJSONArray,
'Messages is not a TJSONArray');
messages := res.BodyAsJsonObject.Get('messages').JsonValue as TJSONArray;
if messages.Size > 0 then
for I := 0 to messages.Size - 1 do
begin
o := messages.Get(I) as TJSONObject;
logw(o.Get('message').ToString);
end;
RMessageCount := RMessageCount + messages.Size;
end;
if res.ResponseCode = HTTP_STATUS.RequestTimeout then // receive timeout
break;
end;
CheckEquals(MSG_COUNT * 2, RMessageCount, 'message count');
res := RESTClient.doGET('/messages', []);
CheckIs(res.BodyAsJsonObject.Get('_timeout').JsonValue, TJSONTrue);
DoLogout;
end;
procedure TMessagingExtensionsTestCase.TestSubscribeOnATopic;
var
res: IRESTResponse;
begin
DoLoginWith('guest');
RESTClient.doPOST('/messages/clients', ['my-unique-id']);
res := RESTClient.doPOST('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
res := RESTClient.doDELETE('/messages/subscriptions/queue/test01', []);
CheckEquals(HTTP_STATUS.OK, res.ResponseCode, res.ResponseText);
DoLogout;
end;
initialization
{$IFDEF USE_MESSAGING}
RegisterTest(TMessagingExtensionsTestCase.Suite);
{$ENDIF}
finalization
end.

View File

@ -1,266 +1,266 @@
unit RESTAdapterTestsU;
interface
uses
MVCFramework.RESTAdapter, TestFramework, BusinessObjectsU,
Generics.Collections,
{$IF CompilerVersion < 27}
Data.DBXJSON,
Data.SqlExpr,
DBXCommon,
{$ELSE}
System.JSON,
{$ENDIF}
ObjectsMappers, MVCFramework.RESTClient, MVCFramework;
type
[Headers('User-Agent', 'RESTAdapter-Test')]
ITESTService = interface(IInvokable)
['{58B9FA23-92F4-4B8E-814B-05232F32A41F}']
[RESTResource(HttpGet, '/people')]
[MapperListOf(TPerson)]
function GetPeople: TObjectList<TPerson>;
[RESTResource(HttpGet, '/people')]
[MapperListOf(TPerson)]
[Mapping(TPeople)]
procedure GetPeopleAsynch(AAsynchRequest: IAsynchRequest);
[RESTResource(HttpGet, '/people/1')]
function GetTonyStark: TPerson;
[RESTResource(HttpGet, '/people/1')]
[Mapping(TPerson)]
procedure GetTonyStarkAsynch(AAsynchRequest: IAsynchRequest);
[RESTResource(HttpGet, '/people/{personid}')]
function GetPersonByID([Param('personid')] APersonID: integer): TPerson;
[RESTResource(httpPOST, '/people')]
function SendPerson([Body] ABody: TPerson): TPerson;
[RESTResource(HttpGet, '/people')]
function GetPersonInJSONArray: TJSONArray;
[Headers('Accept', 'application/json')]
[Headers('ContentType', 'application/json')]
[RESTResource(HttpGet, '/testconsumejson')]
function HeadersApplicationJSON: TJSONValue;
[Headers('Accept', 'text/plain')]
[Headers('ContentType', 'text/plain')]
[RESTResource(HttpGet, '/testconsumes')]
function HeadersTextPlain: string;
[Headers('Accept', 'text/plain')]
[Headers('ContentType', 'text/plain')]
[RESTResource(HttpGet, '/testconsumejson')]
function ApplicationJSONWithTextPlainHeader: IRESTResponse;
end;
TTestRESTAdapter = class(TTestCase)
private
RESTAdapter: TRESTAdapter<ITESTService>;
TESTService: ITESTService;
protected
procedure SetUp; override;
published
procedure TestGetPeople;
procedure TestGetPeopleAsynch;
procedure TestGetTonyStark;
procedure TestGetTonyStarkAsynch;
procedure TestPostPerson;
procedure TestGetPersonByID;
procedure TestHeadersApplicationJSON;
procedure TestHeadersTextPlain;
procedure TestApplicationJSONWithHeaderTextPlain;
procedure TestGetPersonInJSONArray;
end;
implementation
uses System.SysUtils, System.Rtti, System.SyncObjs;
{ TTestRESTAdapter }
procedure TTestRESTAdapter.SetUp;
begin
inherited;
RESTAdapter := TRESTAdapter<ITESTService>.Create;
TESTService := RESTAdapter.Build('localhost', 9999);
end;
procedure TTestRESTAdapter.TestGetPersonByID;
var
Person: TPerson;
begin;
Person := TESTService.GetPersonByID(1);
try
CheckEquals('Tony', Person.FirstName);
CheckEquals('Stark', Person.LastName);
CheckTrue(Person.Married);
finally
Person.Free;
end;
end;
procedure TTestRESTAdapter.TestGetPersonInJSONArray;
var
JSONArray: TJSONArray;
begin
JSONArray := TESTService.GetPersonInJSONArray;
try
CheckTrue(JSONArray.ToString.Contains('Tony'));
CheckTrue(JSONArray.ToString.Contains('Stark'));
CheckTrue(JSONArray.ToString.Contains('Bruce'));
CheckTrue(JSONArray.ToString.Contains('Banner'));
finally
JSONArray.Free;
end;
end;
procedure TTestRESTAdapter.TestGetTonyStark;
var
Person: TPerson;
begin;
Person := TESTService.GetTonyStark;
try
CheckEquals('Tony', Person.FirstName);
CheckEquals('Stark', Person.LastName);
CheckTrue(Person.Married);
finally
Person.Free;
end;
end;
procedure TTestRESTAdapter.TestGetTonyStarkAsynch;
var
AsynchRequest: IAsynchRequest;
Person: TPerson;
LEvt: TEvent;
begin
LEvt := TEvent.Create;
try
AsynchRequest := TAsynchRequest.Create(
procedure(AValue: TValue)
begin
Person := AValue.AsType<TPerson>;
LEvt.SetEvent;
end);
TESTService.GetTonyStarkAsynch(AsynchRequest);
// attend for max 5 seconds
CheckTrue(TWaitResult.wrSignaled = LEvt.WaitFor(5000), 'Timeout request');
CheckNotNull(Person);
try
CheckEquals('Tony', Person.FirstName);
CheckEquals('Stark', Person.LastName);
CheckTrue(Person.Married);
finally
Person.Free;
end;
finally
LEvt.Free;
end;
end;
procedure TTestRESTAdapter.TestHeadersApplicationJSON;
var
Res: TJSONObject;
begin
Res := TESTService.HeadersApplicationJSON as TJSONObject;
try
CheckEquals('Hello World', Res.GetValue('key').Value);
finally
Res.Free;
end;
end;
procedure TTestRESTAdapter.TestHeadersTextPlain;
var
Res: string;
begin
Res := TESTService.HeadersTextPlain;
CheckEquals('Hello World', Res);
end;
procedure TTestRESTAdapter.TestPostPerson;
var
Person: TPerson;
RetPerson: TPerson;
begin
Person := TPerson.GetNew('Peter', 'Parker', 0, false);
RetPerson := TESTService.SendPerson(Person);
try
CheckEquals('Peter', RetPerson.FirstName);
CheckEquals('Parker', RetPerson.LastName);
CheckFalse(RetPerson.Married);
finally
RetPerson.Free;
end;
end;
procedure TTestRESTAdapter.TestApplicationJSONWithHeaderTextPlain;
var
Resp: IRESTResponse;
begin
// expected 404 because is not consumed text/plain
Resp := TESTService.ApplicationJSONWithTextPlainHeader;
CheckEquals(404, Resp.ResponseCode);
end;
procedure TTestRESTAdapter.TestGetPeople;
var
ListPerson: TObjectList<TPerson>;
begin
ListPerson := TESTService.GetPeople;
try
CheckTrue(ListPerson.Count > 0);
CheckEquals('Tony', ListPerson[0].FirstName);
CheckEquals('Stark', ListPerson[0].LastName);
finally
ListPerson.Free;
end;
end;
procedure TTestRESTAdapter.TestGetPeopleAsynch;
var
AsynchRequest: IAsynchRequest;
People: TPeople;
LEvt: TEvent;
begin
LEvt := TEvent.Create;
try
AsynchRequest := TAsynchRequest.Create(
procedure(AValue: TValue)
begin
People := AValue.AsType<TPeople>;
LEvt.SetEvent;
end);
TESTService.GetPeopleAsynch(AsynchRequest);
// attend for max 5 seconds
CheckTrue(TWaitResult.wrSignaled = LEvt.WaitFor(5000), 'Timeout request');
CheckNotNull(People);
try
CheckTrue(People.Count > 0);
CheckEquals('Tony', People[0].FirstName);
CheckEquals('Stark', People[0].LastName);
finally
People.Free;
end;
finally
LEvt.Free;
end;
end;
initialization
RegisterTest(TTestRESTAdapter.suite);
finalization
end.
unit RESTAdapterTestsU;
interface
uses
MVCFramework.RESTAdapter, TestFramework, BusinessObjectsU,
Generics.Collections,
{$IF CompilerVersion < 27}
Data.DBXJSON,
Data.SqlExpr,
DBXCommon,
{$ELSE}
System.JSON,
{$ENDIF}
ObjectsMappers, MVCFramework.RESTClient, MVCFramework;
type
[Headers('User-Agent', 'RESTAdapter-Test')]
ITESTService = interface(IInvokable)
['{58B9FA23-92F4-4B8E-814B-05232F32A41F}']
[RESTResource(HttpGet, '/people')]
[MapperListOf(TPerson)]
function GetPeople: TObjectList<TPerson>;
[RESTResource(HttpGet, '/people')]
[MapperListOf(TPerson)]
[Mapping(TPeople)]
procedure GetPeopleAsynch(AAsynchRequest: IAsynchRequest);
[RESTResource(HttpGet, '/people/1')]
function GetTonyStark: TPerson;
[RESTResource(HttpGet, '/people/1')]
[Mapping(TPerson)]
procedure GetTonyStarkAsynch(AAsynchRequest: IAsynchRequest);
[RESTResource(HttpGet, '/people/{personid}')]
function GetPersonByID([Param('personid')] APersonID: integer): TPerson;
[RESTResource(httpPOST, '/people')]
function SendPerson([Body] ABody: TPerson): TPerson;
[RESTResource(HttpGet, '/people')]
function GetPersonInJSONArray: TJSONArray;
[Headers('Accept', 'application/json')]
[Headers('ContentType', 'application/json')]
[RESTResource(HttpGet, '/testconsumejson')]
function HeadersApplicationJSON: TJSONValue;
[Headers('Accept', 'text/plain')]
[Headers('ContentType', 'text/plain')]
[RESTResource(HttpGet, '/testconsumes')]
function HeadersTextPlain: string;
[Headers('Accept', 'text/plain')]
[Headers('ContentType', 'text/plain')]
[RESTResource(HttpGet, '/testconsumejson')]
function ApplicationJSONWithTextPlainHeader: IRESTResponse;
end;
TTestRESTAdapter = class(TTestCase)
private
RESTAdapter: TRESTAdapter<ITESTService>;
TESTService: ITESTService;
protected
procedure SetUp; override;
published
procedure TestGetPeople;
procedure TestGetPeopleAsynch;
procedure TestGetTonyStark;
procedure TestGetTonyStarkAsynch;
procedure TestPostPerson;
procedure TestGetPersonByID;
procedure TestHeadersApplicationJSON;
procedure TestHeadersTextPlain;
procedure TestApplicationJSONWithHeaderTextPlain;
procedure TestGetPersonInJSONArray;
end;
implementation
uses System.SysUtils, System.Rtti, System.SyncObjs;
{ TTestRESTAdapter }
procedure TTestRESTAdapter.SetUp;
begin
inherited;
RESTAdapter := TRESTAdapter<ITESTService>.Create;
TESTService := RESTAdapter.Build('localhost', 9999);
end;
procedure TTestRESTAdapter.TestGetPersonByID;
var
Person: TPerson;
begin;
Person := TESTService.GetPersonByID(1);
try
CheckEquals('Tony', Person.FirstName);
CheckEquals('Stark', Person.LastName);
CheckTrue(Person.Married);
finally
Person.Free;
end;
end;
procedure TTestRESTAdapter.TestGetPersonInJSONArray;
var
JSONArray: TJSONArray;
begin
JSONArray := TESTService.GetPersonInJSONArray;
try
CheckTrue(JSONArray.ToString.Contains('Tony'));
CheckTrue(JSONArray.ToString.Contains('Stark'));
CheckTrue(JSONArray.ToString.Contains('Bruce'));
CheckTrue(JSONArray.ToString.Contains('Banner'));
finally
JSONArray.Free;
end;
end;
procedure TTestRESTAdapter.TestGetTonyStark;
var
Person: TPerson;
begin;
Person := TESTService.GetTonyStark;
try
CheckEquals('Tony', Person.FirstName);
CheckEquals('Stark', Person.LastName);
CheckTrue(Person.Married);
finally
Person.Free;
end;
end;
procedure TTestRESTAdapter.TestGetTonyStarkAsynch;
var
AsynchRequest: IAsynchRequest;
Person: TPerson;
LEvt: TEvent;
begin
LEvt := TEvent.Create;
try
AsynchRequest := TAsynchRequest.Create(
procedure(AValue: TValue)
begin
Person := AValue.AsType<TPerson>;
LEvt.SetEvent;
end);
TESTService.GetTonyStarkAsynch(AsynchRequest);
// attend for max 5 seconds
CheckTrue(TWaitResult.wrSignaled = LEvt.WaitFor(5000), 'Timeout request');
CheckNotNull(Person);
try
CheckEquals('Tony', Person.FirstName);
CheckEquals('Stark', Person.LastName);
CheckTrue(Person.Married);
finally
Person.Free;
end;
finally
LEvt.Free;
end;
end;
procedure TTestRESTAdapter.TestHeadersApplicationJSON;
var
Res: TJSONObject;
begin
Res := TESTService.HeadersApplicationJSON as TJSONObject;
try
CheckEquals('Hello World', Res.GetValue('key').Value);
finally
Res.Free;
end;
end;
procedure TTestRESTAdapter.TestHeadersTextPlain;
var
Res: string;
begin
Res := TESTService.HeadersTextPlain;
CheckEquals('Hello World', Res);
end;
procedure TTestRESTAdapter.TestPostPerson;
var
Person: TPerson;
RetPerson: TPerson;
begin
Person := TPerson.GetNew('Peter', 'Parker', 0, false);
RetPerson := TESTService.SendPerson(Person);
try
CheckEquals('Peter', RetPerson.FirstName);
CheckEquals('Parker', RetPerson.LastName);
CheckFalse(RetPerson.Married);
finally
RetPerson.Free;
end;
end;
procedure TTestRESTAdapter.TestApplicationJSONWithHeaderTextPlain;
var
Resp: IRESTResponse;
begin
// expected 404 because is not consumed text/plain
Resp := TESTService.ApplicationJSONWithTextPlainHeader;
CheckEquals(404, Resp.ResponseCode);
end;
procedure TTestRESTAdapter.TestGetPeople;
var
ListPerson: TObjectList<TPerson>;
begin
ListPerson := TESTService.GetPeople;
try
CheckTrue(ListPerson.Count > 0);
CheckEquals('Tony', ListPerson[0].FirstName);
CheckEquals('Stark', ListPerson[0].LastName);
finally
ListPerson.Free;
end;
end;
procedure TTestRESTAdapter.TestGetPeopleAsynch;
var
AsynchRequest: IAsynchRequest;
People: TPeople;
LEvt: TEvent;
begin
LEvt := TEvent.Create;
try
AsynchRequest := TAsynchRequest.Create(
procedure(AValue: TValue)
begin
People := AValue.AsType<TPeople>;
LEvt.SetEvent;
end);
TESTService.GetPeopleAsynch(AsynchRequest);
// attend for max 5 seconds
CheckTrue(TWaitResult.wrSignaled = LEvt.WaitFor(5000), 'Timeout request');
CheckNotNull(People);
try
CheckTrue(People.Count > 0);
CheckEquals('Tony', People[0].FirstName);
CheckEquals('Stark', People[0].LastName);
finally
People.Free;
end;
finally
LEvt.Free;
end;
end;
initialization
RegisterTest(TTestRESTAdapter.suite);
finalization
end.

View File

@ -1,112 +1,112 @@
unit TestControllersU;
interface
uses MVCFramework.Commons,
System.Classes,
Web.HTTPApp,
MVCFramework;
type
[MVCPath('/')]
TSimpleController = class(TMVCController)
private
FCalledActions: TStringList;
procedure AddCall(ActionName: string);
protected
procedure MVCControllerAfterCreate; override;
procedure MVCControllerBeforeDestroy; override;
public
[MVCPath('/')]
procedure Index(Context: TWebContext);
[MVCPath('/orders')]
[MVCProduces('application/json')]
procedure OrdersProduceJSON(Context: TWebContext);
[MVCPath('/orders')]
procedure Orders(Context: TWebContext);
[MVCHTTPMethod([httpGET])]
[MVCPath('/orders/($ordernumber)')]
procedure OrderNumber(Context: TWebContext);
[MVCHTTPMethod([httpPOST, httpPUT])]
[MVCPath('/orders/($ordernumber)')]
procedure UpdateOrderNumber(Context: TWebContext);
[MVCHTTPMethod([httpPATCH])]
[MVCPath('/orders/($ordernumber)')]
procedure PatchOrder(Context: TWebContext);
property CalledActions: TStringList read FCalledActions; // only for tests
end;
TNotSoSimpleController = class(TMVCController)
public
procedure Method1(CTX: TWebContext);
end;
implementation
{ TSimpleController }
procedure TSimpleController.AddCall(ActionName: string);
begin
FCalledActions.Add(ActionName);
end;
procedure TSimpleController.Index(Context: TWebContext);
begin
AddCall('Index');
end;
procedure TSimpleController.MVCControllerAfterCreate;
begin
inherited;
FCalledActions := TStringList.Create;
end;
procedure TSimpleController.MVCControllerBeforeDestroy;
begin
FCalledActions.Free;
inherited;
end;
procedure TSimpleController.Orders(Context: TWebContext);
begin
end;
procedure TSimpleController.OrdersProduceJSON(Context: TWebContext);
begin
end;
procedure TSimpleController.PatchOrder(Context: TWebContext);
begin
end;
procedure TSimpleController.UpdateOrderNumber(Context: TWebContext);
begin
end;
procedure TSimpleController.OrderNumber(Context: TWebContext);
begin
end;
{ TNotSoSimpleController }
procedure TNotSoSimpleController.Method1(CTX: TWebContext);
begin
end;
end.
unit TestControllersU;
interface
uses MVCFramework.Commons,
System.Classes,
Web.HTTPApp,
MVCFramework;
type
[MVCPath('/')]
TSimpleController = class(TMVCController)
private
FCalledActions: TStringList;
procedure AddCall(ActionName: string);
protected
procedure MVCControllerAfterCreate; override;
procedure MVCControllerBeforeDestroy; override;
public
[MVCPath('/')]
procedure Index(Context: TWebContext);
[MVCPath('/orders')]
[MVCProduces('application/json')]
procedure OrdersProduceJSON(Context: TWebContext);
[MVCPath('/orders')]
procedure Orders(Context: TWebContext);
[MVCHTTPMethod([httpGET])]
[MVCPath('/orders/($ordernumber)')]
procedure OrderNumber(Context: TWebContext);
[MVCHTTPMethod([httpPOST, httpPUT])]
[MVCPath('/orders/($ordernumber)')]
procedure UpdateOrderNumber(Context: TWebContext);
[MVCHTTPMethod([httpPATCH])]
[MVCPath('/orders/($ordernumber)')]
procedure PatchOrder(Context: TWebContext);
property CalledActions: TStringList read FCalledActions; // only for tests
end;
TNotSoSimpleController = class(TMVCController)
public
procedure Method1(CTX: TWebContext);
end;
implementation
{ TSimpleController }
procedure TSimpleController.AddCall(ActionName: string);
begin
FCalledActions.Add(ActionName);
end;
procedure TSimpleController.Index(Context: TWebContext);
begin
AddCall('Index');
end;
procedure TSimpleController.MVCControllerAfterCreate;
begin
inherited;
FCalledActions := TStringList.Create;
end;
procedure TSimpleController.MVCControllerBeforeDestroy;
begin
FCalledActions.Free;
inherited;
end;
procedure TSimpleController.Orders(Context: TWebContext);
begin
end;
procedure TSimpleController.OrdersProduceJSON(Context: TWebContext);
begin
end;
procedure TSimpleController.PatchOrder(Context: TWebContext);
begin
end;
procedure TSimpleController.UpdateOrderNumber(Context: TWebContext);
begin
end;
procedure TSimpleController.OrderNumber(Context: TWebContext);
begin
end;
{ TNotSoSimpleController }
procedure TNotSoSimpleController.Method1(CTX: TWebContext);
begin
end;
end.

View File

@ -1,4 +1,4 @@
unit MVCFrameworkServerTestsU;
unit MVCFramework.Tests.StandaloneServer;
interface
@ -21,7 +21,7 @@ type
end;
TTestMVCFrameworkServer = class(TTestCase)
private
strict private
protected
procedure SetUp; override;
@ -29,7 +29,6 @@ type
published
procedure TestCreateServer();
procedure TestServerContainer();
procedure TestServerAndClient();
end;
@ -39,7 +38,7 @@ var
implementation
uses
TestWebModuleU,
MVCFramework.Tests.WebModule,
MVCFramework.RESTClient;
{ TTestMVCFrameworkServer }
@ -72,7 +71,10 @@ begin
CheckTrue(vServer.Info <> nil);
vServer.Start;
CheckTrue(vServer.Active);
vServer.Stop;
CheckFalse(vServer.Active);
end;
procedure TTestMVCFrameworkServer.TestServerAndClient;

View File

@ -0,0 +1,13 @@
object TestWebModule: TTestWebModule
OldCreateOrder = False
OnCreate = WebModuleCreate
OnDestroy = WebModuleDestroy
Actions = <
item
Default = True
Name = 'DefaultHandler'
PathInfo = '/'
end>
Height = 230
Width = 415
end

View File

@ -1,4 +1,4 @@
unit TestWebModuleU;
unit MVCFramework.Tests.WebModule;
interface
@ -25,7 +25,7 @@ var
implementation
uses
MVCFrameworkServerTestsU,
MVCFramework.Tests.StandaloneServer,
MVCFramework.Middleware.Authentication,
MVCFramework.Server;

View File

@ -0,0 +1,30 @@
program StandaloneServerTests;
{
Delphi DUnit Test Project
-------------------------
This project contains the DUnit test framework and the GUI/Console test runners.
Add "CONSOLE_TESTRUNNER" to the conditional defines entry in the project options
to use the console test runner. Otherwise the GUI test runner will be used by
default.
}
{$IFDEF CONSOLE_TESTRUNNER}
{$APPTYPE CONSOLE}
{$ENDIF}
uses
DUnitTestRunner,
MVCFramework.Tests.StandaloneServer in 'MVCFramework.Tests.StandaloneServer.pas',
MVCFramework.Tests.WebModule in 'MVCFramework.Tests.WebModule.pas' {TestWebModule: TWebModule};
{$R *.RES}
begin
ReportMemoryLeaksOnShutdown := True;
DUnitTestRunner.RunRegisteredTests;
end.

View File

@ -0,0 +1,550 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{A6820FB8-CB11-495D-BE12-F67C17BED003}</ProjectGuid>
<ProjectVersion>18.1</ProjectVersion>
<FrameworkType>VCL</FrameworkType>
<Base>True</Base>
<Config Condition="'$(Config)'==''">Debug</Config>
<Platform Condition="'$(Platform)'==''">Win32</Platform>
<TargetedPlatforms>1</TargetedPlatforms>
<AppType>Console</AppType>
<MainSource>StandaloneServerTests.dpr</MainSource>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Base' or '$(Base)'!=''">
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Base)'=='true') or '$(Base_Win32)'!=''">
<Base_Win32>true</Base_Win32>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win64' and '$(Base)'=='true') or '$(Base_Win64)'!=''">
<Base_Win64>true</Base_Win64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Debug' or '$(Cfg_1)'!=''">
<Cfg_1>true</Cfg_1>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Cfg_1)'=='true') or '$(Cfg_1_Win32)'!=''">
<Cfg_1_Win32>true</Cfg_1_Win32>
<CfgParent>Cfg_1</CfgParent>
<Cfg_1>true</Cfg_1>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Config)'=='Release' or '$(Cfg_2)'!=''">
<Cfg_2>true</Cfg_2>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Base)'!=''">
<SanitizedProjectName>StandaloneServerTests</SanitizedProjectName>
<VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
<VerInfo_Locale>1046</VerInfo_Locale>
<DCC_Namespace>System;Xml;Data;Datasnap;Web;Soap;Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;$(DCC_Namespace)</DCC_Namespace>
<DCC_UnitSearchPath>$(BDS)\Source\DUnit\src;..\..\sources;..\..\lib\iocpdelphiframework\Base;..\..\lib\iocpdelphiframework\Core;..\..\lib\iocpdelphiframework\Extensions;..\..\lib\delphistompclient;..\..\lib\dmustache;$(DCC_UnitSearchPath)</DCC_UnitSearchPath>
<DCC_DcpOutput>.\$(Platform)\$(Config)\dcp</DCC_DcpOutput>
<DCC_BplOutput>.\$(Platform)\$(Config)\pkg</DCC_BplOutput>
<DCC_Define>_CONSOLE_TESTRUNNER;$(DCC_Define)</DCC_Define>
<DCC_DcuOutput>.\$(Platform)\$(Config)\dcu</DCC_DcuOutput>
<DCC_ExeOutput>.\$(Platform)\$(Config)</DCC_ExeOutput>
<DCC_E>false</DCC_E>
<DCC_N>false</DCC_N>
<DCC_S>false</DCC_S>
<DCC_F>false</DCC_F>
<DCC_K>false</DCC_K>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win32)'!=''">
<DCC_Namespace>Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace)</DCC_Namespace>
<DCC_UsePackage>DBXSqliteDriver;RESTComponents;DataSnapServerMidas;DBXDb2Driver;DBXInterBaseDriver;vclactnband;vclFireDAC;emsclientfiredac;DataSnapFireDAC;tethering;svnui;FireDACADSDriver;DBXMSSQLDriver;DatasnapConnectorsFreePascal;FireDACMSSQLDriver;vcltouch;vcldb;bindcompfmx;Intraweb;svn;DBXOracleDriver;inetdb;FmxTeeUI;FireDACIBDriver;fmx;fmxdae;vclib;FireDACDBXDriver;dbexpress;IndyCore;vclx;dsnap;DataSnapCommon;emsclient;FireDACCommon;RESTBackendComponents;DataSnapConnectors;VCLRESTComponents;soapserver;vclie;bindengine;DBXMySQLDriver;CloudService;FireDACOracleDriver;FireDACMySQLDriver;DBXFirebirdDriver;FireDACCommonDriver;DataSnapClient;inet;bindcompdbx;IndyIPCommon;vcl;DBXSybaseASEDriver;IndyIPServer;IndySystem;FireDACDb2Driver;dsnapcon;FireDACMSAccDriver;FireDACInfxDriver;fmxFireDAC;vclimg;TeeDB;FireDAC;FireDACSqliteDriver;FireDACPgDriver;ibmonitor;FireDACASADriver;DBXOdbcDriver;FireDACTDataDriver;FMXTee;soaprtl;DbxCommonDriver;ibxpress;Tee;DataSnapServer;xmlrtl;DataSnapNativeClient;ibxbindings;fmxobj;FireDACDSDriver;soapmidas;rtl;vclwinx;DbxClientDriver;DBXSybaseASADriver;CustomIPTransport;vcldsnap;bindcomp;appanalytics;DBXInformixDriver;IndyIPClient;bindcompvcl;TeeUI;vclribbon;dbxcds;VclSmp;adortl;FireDACODBCDriver;DataSnapIndy10ServerTransport;DataSnapProviderClient;dsnapxml;dbrtl;FireDACMongoDBDriver;IndyProtocols;inetdbxpress;fmxase;$(DCC_UsePackage)</DCC_UsePackage>
<VerInfo_Locale>1033</VerInfo_Locale>
<VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win64)'!=''">
<DCC_UsePackage>DBXSqliteDriver;RESTComponents;DataSnapServerMidas;DBXDb2Driver;DBXInterBaseDriver;vclactnband;vclFireDAC;emsclientfiredac;DataSnapFireDAC;tethering;FireDACADSDriver;DBXMSSQLDriver;DatasnapConnectorsFreePascal;FireDACMSSQLDriver;vcltouch;vcldb;bindcompfmx;Intraweb;DBXOracleDriver;inetdb;FmxTeeUI;FireDACIBDriver;fmx;fmxdae;vclib;FireDACDBXDriver;dbexpress;IndyCore;vclx;dsnap;DataSnapCommon;emsclient;FireDACCommon;RESTBackendComponents;DataSnapConnectors;VCLRESTComponents;soapserver;vclie;bindengine;DBXMySQLDriver;CloudService;FireDACOracleDriver;FireDACMySQLDriver;DBXFirebirdDriver;FireDACCommonDriver;DataSnapClient;inet;bindcompdbx;IndyIPCommon;vcl;DBXSybaseASEDriver;IndyIPServer;IndySystem;FireDACDb2Driver;dsnapcon;FireDACMSAccDriver;FireDACInfxDriver;fmxFireDAC;vclimg;TeeDB;FireDAC;FireDACSqliteDriver;FireDACPgDriver;ibmonitor;FireDACASADriver;DBXOdbcDriver;FireDACTDataDriver;FMXTee;soaprtl;DbxCommonDriver;ibxpress;Tee;DataSnapServer;xmlrtl;DataSnapNativeClient;ibxbindings;fmxobj;FireDACDSDriver;soapmidas;rtl;vclwinx;DbxClientDriver;DBXSybaseASADriver;CustomIPTransport;vcldsnap;bindcomp;appanalytics;DBXInformixDriver;IndyIPClient;bindcompvcl;TeeUI;vclribbon;dbxcds;VclSmp;adortl;FireDACODBCDriver;DataSnapIndy10ServerTransport;DataSnapProviderClient;dsnapxml;dbrtl;FireDACMongoDBDriver;IndyProtocols;inetdbxpress;fmxase;$(DCC_UsePackage)</DCC_UsePackage>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_1)'!=''">
<DCC_Define>DEBUG;$(DCC_Define)</DCC_Define>
<DCC_DebugDCUs>true</DCC_DebugDCUs>
<DCC_Optimize>false</DCC_Optimize>
<DCC_GenerateStackFrames>true</DCC_GenerateStackFrames>
<DCC_DebugInfoInExe>true</DCC_DebugInfoInExe>
<DCC_RemoteDebug>true</DCC_RemoteDebug>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_1_Win32)'!=''">
<Manifest_File>None</Manifest_File>
<VerInfo_Locale>1033</VerInfo_Locale>
<DCC_RemoteDebug>false</DCC_RemoteDebug>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2)'!=''">
<DCC_LocalDebugSymbols>false</DCC_LocalDebugSymbols>
<DCC_Define>RELEASE;$(DCC_Define)</DCC_Define>
<DCC_SymbolReferenceInfo>0</DCC_SymbolReferenceInfo>
<DCC_DebugInformation>0</DCC_DebugInformation>
</PropertyGroup>
<ItemGroup>
<DelphiCompile Include="$(MainSource)">
<MainSource>MainSource</MainSource>
</DelphiCompile>
<DCCReference Include="MVCFramework.Tests.StandaloneServer.pas"/>
<DCCReference Include="MVCFramework.Tests.WebModule.pas">
<Form>TestWebModule</Form>
<FormType>dfm</FormType>
<DesignClass>TWebModule</DesignClass>
</DCCReference>
<BuildConfiguration Include="Release">
<Key>Cfg_2</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
<BuildConfiguration Include="Base">
<Key>Base</Key>
</BuildConfiguration>
<BuildConfiguration Include="Debug">
<Key>Cfg_1</Key>
<CfgParent>Base</CfgParent>
</BuildConfiguration>
</ItemGroup>
<ProjectExtensions>
<Borland.Personality>Delphi.Personality.12</Borland.Personality>
<Borland.ProjectType>Application</Borland.ProjectType>
<BorlandProject>
<Delphi.Personality>
<Excluded_Packages>
<Excluded_Packages Name="$(BDSBIN)\dcloffice2k230.bpl">Microsoft Office 2000 Sample Automation Server Wrapper Components</Excluded_Packages>
<Excluded_Packages Name="$(BDSBIN)\dclofficexp230.bpl">Microsoft Office XP Sample Automation Server Wrapper Components</Excluded_Packages>
</Excluded_Packages>
<Source>
<Source Name="MainSource">StandaloneServerTests.dpr</Source>
</Source>
</Delphi.Personality>
<Deployment Version="2">
<DeployFile LocalName="$(BDS)\Redist\osx32\libcgunwind.1.0.dylib" Class="DependencyModule">
<Platform Name="OSX32">
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployFile LocalName="$(BDS)\Redist\iossimulator\libcgunwind.1.0.dylib" Class="DependencyModule">
<Platform Name="iOSSimulator">
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployFile LocalName="$(BDS)\Redist\iossimulator\libPCRE.dylib" Class="DependencyModule">
<Platform Name="iOSSimulator">
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployFile LocalName="Win32\Debug\StandaloneServerTests.exe" Configuration="Debug" Class="ProjectOutput">
<Platform Name="Win32">
<RemoteName>StandaloneServerTests.exe</RemoteName>
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployClass Name="DependencyModule">
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.dll;.bpl</Extensions>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOSXResource">
<Platform Name="OSX32">
<RemoteDir>Contents\Resources</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidClassesDexFile">
<Platform Name="Android">
<RemoteDir>classes</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AdditionalDebugSymbols">
<Platform Name="Win32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>0</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch768">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon144">
<Platform Name="Android">
<RemoteDir>res\drawable-xxhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeMipsFile">
<Platform Name="Android">
<RemoteDir>library\lib\mips</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Required="true" Name="ProjectOutput">
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DependencyFramework">
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
<Extensions>.framework</Extensions>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch640">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch1024">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSDeviceDebug">
<Platform Name="iOSDevice64">
<RemoteDir>..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<RemoteDir>..\$(PROJECTNAME).app.dSYM\Contents\Resources\DWARF</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeX86File">
<Platform Name="Android">
<RemoteDir>library\lib\x86</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch320">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSInfoPList">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidLibnativeArmeabiFile">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="DebugSymbols">
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch1536">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage470">
<Platform Name="Android">
<RemoteDir>res\drawable-normal</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon96">
<Platform Name="Android">
<RemoteDir>res\drawable-xhdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage640">
<Platform Name="Android">
<RemoteDir>res\drawable-large</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPhone_Launch640x1136">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSEntitlements">
<Platform Name="iOSDevice64">
<RemoteDir>../</RemoteDir>
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<RemoteDir>../</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon72">
<Platform Name="Android">
<RemoteDir>res\drawable-hdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidGDBServer">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOSXInfoPList">
<Platform Name="OSX32">
<RemoteDir>Contents</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectOSXEntitlements">
<Platform Name="OSX32">
<RemoteDir>../</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="iPad_Launch2048">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashStyles">
<Platform Name="Android">
<RemoteDir>res\values</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage426">
<Platform Name="Android">
<RemoteDir>res\drawable-small</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidSplashImageDef">
<Platform Name="Android">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSResource">
<Platform Name="iOSSimulator">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectAndroidManifest">
<Platform Name="Android">
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_DefaultAppIcon">
<Platform Name="Android">
<RemoteDir>res\drawable</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="File">
<Platform Name="Win32">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice64">
<Operation>0</Operation>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\Resources\StartUp\</RemoteDir>
<Operation>0</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>0</Operation>
</Platform>
<Platform Name="Android">
<Operation>0</Operation>
</Platform>
<Platform Name="iOSSimulator">
<Operation>0</Operation>
</Platform>
</DeployClass>
<DeployClass Name="AndroidServiceOutput">
<Platform Name="Android">
<RemoteDir>library\lib\armeabi-v7a</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Required="true" Name="DependencyPackage">
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.bpl</Extensions>
</Platform>
<Platform Name="iOSDevice64">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="OSX32">
<RemoteDir>Contents\MacOS</RemoteDir>
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
<Platform Name="iOSSimulator">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon48">
<Platform Name="Android">
<RemoteDir>res\drawable-mdpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_SplashImage960">
<Platform Name="Android">
<RemoteDir>res\drawable-xlarge</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="Android_LauncherIcon36">
<Platform Name="Android">
<RemoteDir>res\drawable-ldpi</RemoteDir>
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSDeviceResourceRules">
<Platform Name="iOSDevice64">
<Operation>1</Operation>
</Platform>
<Platform Name="iOSDevice32">
<Operation>1</Operation>
</Platform>
</DeployClass>
<ProjectRoot Platform="iOSDevice64" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Win64" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="iOSDevice32" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Win32" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="OSX32" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Android" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="iOSSimulator" Name="$(PROJECTNAME).app"/>
</Deployment>
<Platforms>
<Platform value="Win32">True</Platform>
<Platform value="Win64">False</Platform>
</Platforms>
<UnitTesting>
<TestFramework>DUnit / Delphi Win32</TestFramework>
<TestRunner>GUI</TestRunner>
<TestProjectName/>
<SourceProjectName/>
</UnitTesting>
</BorlandProject>
<ProjectFileVersion>12</ProjectFileVersion>
</ProjectExtensions>
<Import Project="$(BDS)\Bin\CodeGear.Delphi.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Delphi.Targets')"/>
<Import Project="$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj" Condition="Exists('$(APPDATA)\Embarcadero\$(BDSAPPDATABASEDIR)\$(PRODUCTVERSION)\UserTools.proj')"/>
<Import Project="$(MSBuildProjectName).deployproj" Condition="Exists('$(MSBuildProjectName).deployproj')"/>
</Project>

Binary file not shown.

View File

@ -1,48 +0,0 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<ProjectGuid>{05A61BAB-DCAC-4484-8D04-9F8BBC002114}</ProjectGuid>
</PropertyGroup>
<ItemGroup>
<Projects Include="DMVCFrameworkTests\DMVCFrameworkTests.dproj">
<Dependencies/>
</Projects>
<Projects Include="TestServer\TestServer.dproj">
<Dependencies/>
</Projects>
</ItemGroup>
<ProjectExtensions>
<Borland.Personality>Default.Personality.12</Borland.Personality>
<Borland.ProjectType/>
<BorlandProject>
<Default.Personality/>
</BorlandProject>
</ProjectExtensions>
<Target Name="DMVCFrameworkTests">
<MSBuild Projects="DMVCFrameworkTests\DMVCFrameworkTests.dproj"/>
</Target>
<Target Name="DMVCFrameworkTests:Clean">
<MSBuild Projects="DMVCFrameworkTests\DMVCFrameworkTests.dproj" Targets="Clean"/>
</Target>
<Target Name="DMVCFrameworkTests:Make">
<MSBuild Projects="DMVCFrameworkTests\DMVCFrameworkTests.dproj" Targets="Make"/>
</Target>
<Target Name="TestServer">
<MSBuild Projects="TestServer\TestServer.dproj"/>
</Target>
<Target Name="TestServer:Clean">
<MSBuild Projects="TestServer\TestServer.dproj" Targets="Clean"/>
</Target>
<Target Name="TestServer:Make">
<MSBuild Projects="TestServer\TestServer.dproj" Targets="Make"/>
</Target>
<Target Name="Build">
<CallTarget Targets="DMVCFrameworkTests;TestServer"/>
</Target>
<Target Name="Clean">
<CallTarget Targets="DMVCFrameworkTests:Clean;TestServer:Clean"/>
</Target>
<Target Name="Make">
<CallTarget Targets="DMVCFrameworkTests:Make;TestServer:Make"/>
</Target>
<Import Project="$(BDS)\Bin\CodeGear.Group.Targets" Condition="Exists('$(BDS)\Bin\CodeGear.Group.Targets')"/>
</Project>

View File

@ -9,28 +9,10 @@ uses
Web.WebReq,
Web.WebBroker,
WebModuleUnit in 'WebModuleUnit.pas' {wm: TWebModule},
MVCFramework in '..\..\sources\MVCFramework.pas',
MVCFramework.RESTClient in '..\..\sources\MVCFramework.RESTClient.pas',
MVCFramework.Router in '..\..\sources\MVCFramework.Router.pas',
MVCFramework.View.Cache in '..\..\sources\MVCFramework.View.Cache.pas',
MVCFramework.View in '..\..\sources\MVCFramework.View.pas',
TestServerControllerU in 'TestServerControllerU.pas',
MVCFramework.ApplicationSession in '..\..\sources\MVCFramework.ApplicationSession.pas',
MVCFramework.Session in '..\..\sources\MVCFramework.Session.pas',
MVCFramework.Logger in '..\..\sources\MVCFramework.Logger.pas',
StompClient in '..\..\lib\delphistompclient\StompClient.pas',
StompTypes in '..\..\lib\delphistompclient\StompTypes.pas',
RTTIUtilsU in '..\..\sources\RTTIUtilsU.pas',
ObjectsMappers in '..\..\sources\ObjectsMappers.pas',
DuckListU in '..\..\sources\DuckListU.pas',
MVCFramework.MessagingController in '..\..\sources\MVCFramework.MessagingController.pas',
BusinessObjectsU in '..\..\samples\commons\BusinessObjectsU.pas',
TestServerControllerExceptionU in 'TestServerControllerExceptionU.pas',
SpeedMiddlewareU in 'SpeedMiddlewareU.pas',
uGlobalVars in '..\..\sources\uGlobalVars.pas' {$R *.res},
MVCFramework.Middleware.Authentication in '..\..\sources\MVCFramework.Middleware.Authentication.pas',
MVCFramework.Commons in '..\..\sources\MVCFramework.Commons.pas',
MVCFramework.SysControllers in '..\..\sources\MVCFramework.SysControllers.pas';
SpeedMiddlewareU in 'SpeedMiddlewareU.pas';
{$R *.res}

View File

@ -13,31 +13,6 @@
<PropertyGroup Condition="'$(Config)'=='Base' or '$(Base)'!=''">
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Android' and '$(Base)'=='true') or '$(Base_Android)'!=''">
<Base_Android>true</Base_Android>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='iOSDevice32' and '$(Base)'=='true') or '$(Base_iOSDevice32)'!=''">
<Base_iOSDevice32>true</Base_iOSDevice32>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='iOSDevice64' and '$(Base)'=='true') or '$(Base_iOSDevice64)'!=''">
<Base_iOSDevice64>true</Base_iOSDevice64>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='iOSSimulator' and '$(Base)'=='true') or '$(Base_iOSSimulator)'!=''">
<Base_iOSSimulator>true</Base_iOSSimulator>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='OSX32' and '$(Base)'=='true') or '$(Base_OSX32)'!=''">
<Base_OSX32>true</Base_OSX32>
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Base)'=='true') or '$(Base_Win32)'!=''">
<Base_Win32>true</Base_Win32>
<CfgParent>Base</CfgParent>
@ -64,12 +39,23 @@
<CfgParent>Base</CfgParent>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="('$(Platform)'=='Win32' and '$(Cfg_2)'=='true') or '$(Cfg_2_Win32)'!=''">
<Cfg_2_Win32>true</Cfg_2_Win32>
<CfgParent>Cfg_2</CfgParent>
<Cfg_2>true</Cfg_2>
<Base>true</Base>
</PropertyGroup>
<PropertyGroup Condition="'$(Base)'!=''">
<VerInfo_Locale>1046</VerInfo_Locale>
<DCC_UnitSearchPath>$(BDS)\Source\DUnit\src;..\..\sources;..\..\lib\iocpdelphiframework\Base;..\..\lib\iocpdelphiframework\Core;..\..\lib\iocpdelphiframework\Extensions;..\..\lib\delphistompclient;..\..\lib\dmustache;$(DCC_UnitSearchPath)</DCC_UnitSearchPath>
<VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
<DCC_DcpOutput>.\$(Platform)\$(Config)\dcp</DCC_DcpOutput>
<DCC_BplOutput>.\$(Platform)\$(Config)\pkg</DCC_BplOutput>
<Icns_MainIcns>$(BDS)\bin\delphi_PROJECTICNS.icns</Icns_MainIcns>
<SanitizedProjectName>TestServer</SanitizedProjectName>
<Icon_MainIcon>$(BDS)\bin\delphi_PROJECTICON.ico</Icon_MainIcon>
<DCC_Namespace>System;Xml;Data;Datasnap;Web;Soap;Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;$(DCC_Namespace)</DCC_Namespace>
<DCC_DcuOutput>.\$(Platform)\$(Config)</DCC_DcuOutput>
<DCC_Namespace>Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;System;Xml;Data;Datasnap;Web;Soap;Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;$(DCC_Namespace)</DCC_Namespace>
<DCC_DcuOutput>.\$(Platform)\$(Config)\dcu</DCC_DcuOutput>
<DCC_ExeOutput>.\$(Platform)\$(Config)</DCC_ExeOutput>
<DCC_E>false</DCC_E>
<DCC_N>false</DCC_N>
@ -77,97 +63,12 @@
<DCC_F>false</DCC_F>
<DCC_K>false</DCC_K>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Android)'!=''">
<AUP_CALL_PHONE>true</AUP_CALL_PHONE>
<AUP_READ_PHONE_STATE>true</AUP_READ_PHONE_STATE>
<AUP_WRITE_EXTERNAL_STORAGE>true</AUP_WRITE_EXTERNAL_STORAGE>
<Android_LauncherIcon48>$(BDS)\bin\Artwork\Android\FM_LauncherIcon_48x48.png</Android_LauncherIcon48>
<Android_LauncherIcon144>$(BDS)\bin\Artwork\Android\FM_LauncherIcon_144x144.png</Android_LauncherIcon144>
<Android_LauncherIcon72>$(BDS)\bin\Artwork\Android\FM_LauncherIcon_72x72.png</Android_LauncherIcon72>
<Android_SplashImage640>$(BDS)\bin\Artwork\Android\FM_SplashImage_640x480.png</Android_SplashImage640>
<AUP_READ_CALENDAR>true</AUP_READ_CALENDAR>
<AUP_ACCESS_FINE_LOCATION>true</AUP_ACCESS_FINE_LOCATION>
<Android_SplashImage960>$(BDS)\bin\Artwork\Android\FM_SplashImage_960x720.png</Android_SplashImage960>
<AUP_CAMERA>true</AUP_CAMERA>
<EnabledSysJars>android-support-v4.dex.jar;apk-expansion.dex.jar;cloud-messaging.dex.jar;fmx.dex.jar;google-analytics-v2.dex.jar;google-play-billing.dex.jar;google-play-licensing.dex.jar;google-play-services.dex.jar</EnabledSysJars>
<AUP_INTERNET>true</AUP_INTERNET>
<VerInfo_Keys>package=com.embarcadero.$(MSBuildProjectName);label=$(MSBuildProjectName);versionCode=1;versionName=1.0.0;persistent=False;restoreAnyVersion=False;installLocation=auto;largeHeap=False;theme=TitleBar;hardwareAccelerated=true;apiKey=</VerInfo_Keys>
<Android_SplashImage426>$(BDS)\bin\Artwork\Android\FM_SplashImage_426x320.png</Android_SplashImage426>
<Android_LauncherIcon96>$(BDS)\bin\Artwork\Android\FM_LauncherIcon_96x96.png</Android_LauncherIcon96>
<AUP_WRITE_CALENDAR>true</AUP_WRITE_CALENDAR>
<Android_LauncherIcon36>$(BDS)\bin\Artwork\Android\FM_LauncherIcon_36x36.png</Android_LauncherIcon36>
<Android_SplashImage470>$(BDS)\bin\Artwork\Android\FM_SplashImage_470x320.png</Android_SplashImage470>
<AUP_ACCESS_COARSE_LOCATION>true</AUP_ACCESS_COARSE_LOCATION>
<BT_BuildType>Debug</BT_BuildType>
<AUP_READ_EXTERNAL_STORAGE>true</AUP_READ_EXTERNAL_STORAGE>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_iOSDevice32)'!=''">
<iPad_Launch1536x2048>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImagePortrait_1536x2048.png</iPad_Launch1536x2048>
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
<iPad_Launch768x1024>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImagePortrait_768x1024.png</iPad_Launch768x1024>
<iPad_Launch2048x1536>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImageLandscape_2048x1536.png</iPad_Launch2048x1536>
<iPhone_AppIcon120>$(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_120x120.png</iPhone_AppIcon120>
<iPhone_AppIcon60>$(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_60x60.png</iPhone_AppIcon60>
<iPhone_Spotlight80>$(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_80x80.png</iPhone_Spotlight80>
<iPhone_Spotlight40>$(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_40x40.png</iPhone_Spotlight40>
<iPad_SpotLight40>$(BDS)\bin\Artwork\iOS\iPad\FM_SpotlightSearchIcon_40x40.png</iPad_SpotLight40>
<VerInfo_UIDeviceFamily>iPhoneAndiPad</VerInfo_UIDeviceFamily>
<VerInfo_Keys>CFBundleName=$(MSBuildProjectName);CFBundleDevelopmentRegion=en;CFBundleDisplayName=$(MSBuildProjectName);CFBundleIdentifier=$(MSBuildProjectName);CFBundleInfoDictionaryVersion=7.1;CFBundleVersion=1.0.0.0;CFBundlePackageType=APPL;CFBundleSignature=????;LSRequiresIPhoneOS=true;CFBundleAllowMixedLocalizations=YES;CFBundleExecutable=$(MSBuildProjectName);UIDeviceFamily=iPhone &amp; iPad;CFBundleResourceSpecification=ResourceRules.plist;NSLocationAlwaysUsageDescription=The reason for accessing the location information of the user;NSLocationWhenInUseUsageDescription=The reason for accessing the location information of the user;FMLocalNotificationPermission=false;UIBackgroundModes=</VerInfo_Keys>
<iPad_Launch1024x768>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImageLandscape_1024x768.png</iPad_Launch1024x768>
<iPad_AppIcon152>$(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_152x152.png</iPad_AppIcon152>
<VerInfo_BundleId>$(MSBuildProjectName)</VerInfo_BundleId>
<iPad_SpotLight80>$(BDS)\bin\Artwork\iOS\iPad\FM_SpotlightSearchIcon_80x80.png</iPad_SpotLight80>
<iPad_AppIcon76>$(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_76x76.png</iPad_AppIcon76>
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_iOSDevice64)'!=''">
<iPad_Launch1536x2048>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImagePortrait_1536x2048.png</iPad_Launch1536x2048>
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
<iPad_Launch768x1024>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImagePortrait_768x1024.png</iPad_Launch768x1024>
<iPad_Launch2048x1536>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImageLandscape_2048x1536.png</iPad_Launch2048x1536>
<iPhone_AppIcon120>$(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_120x120.png</iPhone_AppIcon120>
<iPhone_AppIcon60>$(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_60x60.png</iPhone_AppIcon60>
<iPhone_Spotlight80>$(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_80x80.png</iPhone_Spotlight80>
<iPhone_Spotlight40>$(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_40x40.png</iPhone_Spotlight40>
<iPad_SpotLight40>$(BDS)\bin\Artwork\iOS\iPad\FM_SpotlightSearchIcon_40x40.png</iPad_SpotLight40>
<VerInfo_UIDeviceFamily>iPhoneAndiPad</VerInfo_UIDeviceFamily>
<VerInfo_Keys>CFBundleName=$(MSBuildProjectName);CFBundleDevelopmentRegion=en;CFBundleDisplayName=$(MSBuildProjectName);CFBundleIdentifier=$(MSBuildProjectName);CFBundleInfoDictionaryVersion=7.1;CFBundleVersion=1.0.0.0;CFBundlePackageType=APPL;CFBundleSignature=????;LSRequiresIPhoneOS=true;CFBundleAllowMixedLocalizations=YES;CFBundleExecutable=$(MSBuildProjectName);UIDeviceFamily=iPhone &amp; iPad;CFBundleResourceSpecification=ResourceRules.plist;NSLocationAlwaysUsageDescription=The reason for accessing the location information of the user;NSLocationWhenInUseUsageDescription=The reason for accessing the location information of the user;FMLocalNotificationPermission=false;UIBackgroundModes=</VerInfo_Keys>
<iPad_Launch1024x768>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImageLandscape_1024x768.png</iPad_Launch1024x768>
<iPad_AppIcon152>$(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_152x152.png</iPad_AppIcon152>
<VerInfo_BundleId>$(MSBuildProjectName)</VerInfo_BundleId>
<iPad_SpotLight80>$(BDS)\bin\Artwork\iOS\iPad\FM_SpotlightSearchIcon_80x80.png</iPad_SpotLight80>
<iPad_AppIcon76>$(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_76x76.png</iPad_AppIcon76>
<BT_BuildType>Debug</BT_BuildType>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_iOSSimulator)'!=''">
<VerInfo_IncludeVerInfo>true</VerInfo_IncludeVerInfo>
<iPad_Launch1536x2048>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImagePortrait_1536x2048.png</iPad_Launch1536x2048>
<iPad_Launch2048x1536>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImageLandscape_2048x1536.png</iPad_Launch2048x1536>
<iPhone_Spotlight80>$(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_80x80.png</iPhone_Spotlight80>
<iPhone_AppIcon60>$(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_60x60.png</iPhone_AppIcon60>
<iPhone_AppIcon120>$(BDS)\bin\Artwork\iOS\iPhone\FM_ApplicationIcon_120x120.png</iPhone_AppIcon120>
<iPhone_Spotlight40>$(BDS)\bin\Artwork\iOS\iPhone\FM_SpotlightSearchIcon_40x40.png</iPhone_Spotlight40>
<iPad_Launch768x1024>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImagePortrait_768x1024.png</iPad_Launch768x1024>
<VerInfo_UIDeviceFamily>iPhoneAndiPad</VerInfo_UIDeviceFamily>
<iPad_AppIcon152>$(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_152x152.png</iPad_AppIcon152>
<iPad_Launch1024x768>$(BDS)\bin\Artwork\iOS\iPad\FM_LaunchImageLandscape_1024x768.png</iPad_Launch1024x768>
<VerInfo_Keys>CFBundleName=$(MSBuildProjectName);CFBundleDevelopmentRegion=en;CFBundleDisplayName=$(MSBuildProjectName);CFBundleIdentifier=$(MSBuildProjectName);CFBundleInfoDictionaryVersion=7.1;CFBundleVersion=1.0.0.0;CFBundlePackageType=APPL;CFBundleSignature=????;LSRequiresIPhoneOS=true;CFBundleAllowMixedLocalizations=YES;CFBundleExecutable=$(MSBuildProjectName);UIDeviceFamily=iPhone &amp; iPad;CFBundleResourceSpecification=ResourceRules.plist;NSLocationAlwaysUsageDescription=The reason for accessing the location information of the user;NSLocationWhenInUseUsageDescription=The reason for accessing the location information of the user;FMLocalNotificationPermission=false;UIBackgroundModes=</VerInfo_Keys>
<iPad_SpotLight40>$(BDS)\bin\Artwork\iOS\iPad\FM_SpotlightSearchIcon_40x40.png</iPad_SpotLight40>
<iPad_SpotLight80>$(BDS)\bin\Artwork\iOS\iPad\FM_SpotlightSearchIcon_80x80.png</iPad_SpotLight80>
<iPad_AppIcon76>$(BDS)\bin\Artwork\iOS\iPad\FM_ApplicationIcon_76x76.png</iPad_AppIcon76>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_OSX32)'!=''">
<BT_BuildType>Debug</BT_BuildType>
<VerInfo_Keys>CFBundleName=$(MSBuildProjectName);CFBundleDisplayName=$(MSBuildProjectName);CFBundleIdentifier=$(MSBuildProjectName);CFBundleVersion=1.0.0;CFBundlePackageType=APPL;CFBundleSignature=????;CFBundleAllowMixedLocalizations=YES;CFBundleExecutable=$(MSBuildProjectName);NSHighResolutionCapable=true;LSApplicationCategoryType=public.app-category.utilities;NSLocationAlwaysUsageDescription=The reason for accessing the location information of the user;NSLocationWhenInUseUsageDescription=The reason for accessing the location information of the user</VerInfo_Keys>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win32)'!=''">
<DCC_Define>TEST;$(DCC_Define)</DCC_Define>
<DCC_UnitSearchPath>..\..\sources;..\..\lib\LuaDelphiBinding;..\..\lib\iocpdelphiframework;..\..\lib\delphistompclient;..\..\lib\iocpdelphiframework\Base;$(DCC_UnitSearchPath)</DCC_UnitSearchPath>
<Manifest_File>None</Manifest_File>
<DCC_UsePackage>cxPivotGridChartRS17;JvMM;dxSkinSevenRS17;dxSkinBlueprintRS17;dxSkinHighContrastRS17;dxSkinOffice2007BlackRS17;dxCoreRS17;cxPageControldxBarPopupMenuRS17;dxSkinXmas2008BlueRS17;dxPSDBTeeChartRS17;JvCrypt;dxPSTeeChartRS17;dxSkinSummer2008RS17;dxPScxSchedulerLnkRS17;dxSkinBlueRS17;dxSkinDarkRoomRS17;DBXInterBaseDriver;DataSnapServer;DataSnapCommon;dxPScxTLLnkRS17;JvNet;JvDotNetCtrls;dxRibbonRS17;DbxCommonDriver;cxDataRS17;vclimg;dxSkinsdxBarPainterRS17;dxPSdxDBTVLnkRS17;dbxcds;DatasnapConnectorsFreePascal;NxDBGridDsgn_dxe3;JvXPCtrls;dxSkinMoneyTwinsRS17;vcldb;cxExportRS17;dxPSCoreRS17;dxBarExtItemsRS17;dxGDIPlusRS17;FMXfrx17;dxNavBarRS17;CustomIPTransport;cxLibraryRS17;cxGridRS17;dxSkinOffice2010BlackRS17;dsnap;IndyIPServer;IndyCore;dxSkinMcSkinRS17;CloudService;dxPScxCommonRS17;FmxTeeUI;frxDB17;AnyDAC_PhysDb2_D17;dxSkinsdxDLPainterRS17;dxSkiniMaginaryRS17;JvDB;JvRuntimeDesign;dxPScxVGridLnkRS17;JclDeveloperTools;dxSkinSevenClassicRS17;dxPScxExtCommonRS17;MyFrameTestPackage;dxPScxSSLnkRS17;NxGridRun_dxe3;dxSkinLilianRS17;fs17;dxPSdxLCLnkRS17;dxSkinOffice2010BlueRS17;NxCommonRun_dxe3;bindcompfmx;DataBindingsVCL170;dxSkinOffice2010SilverRS17;vcldbx;cxSchedulerGridRS17;dbrtl;bindcomp;inetdb;JvPluginSystem;dxBarRS17;DataBindings;DBXOdbcDriver;IcsCommonDXE3Run;JvCmp;dxBarDBNavRS17;dxSkinWhiteprintRS17;JvTimeFramework;xmlrtl;dxSkinsdxRibbonPainterRS17;ibxpress;dxDockingRS17;vclactnband;bindengine;soaprtl;FMXTee;dxADOServerModeRS17;bindcompvcl;dxBarExtDBItemsRS17;dxPSPrVwRibbonRS17;Jcl;vclie;dxSkinOffice2007PinkRS17;cxPageControlRS17;dxSkinscxPCPainterRS17;AnyDAC_PhysADS_D17;AnyDAC_PhysIB_D17;dxmdsRS17;dxSkinTheAsphaltWorldRS17;DBXInformixDriver;Intraweb;dxPsPrVwAdvRS17;NxInspectorRun_dxe3;dxSkinSilverRS17;dxdborRS17;dsnapcon;DBXFirebirdDriver;fsDB17;inet;dorm_runtime_xe3;JvPascalInterpreter;vclx;dxSkinStardustRS17;cxEditorsRS17;DBXSybaseASADriver;NxInspectorDsgn_dxe3;dbexpress;IndyIPClient;AnyDAC_PhysMySQL_D17;cxTreeListdxBarPopupMenuRS17;dxSkinVS2010RS17;NxGridDsgn_dxe3;dxThemeRS17;DBXSqliteDriver;dxPScxGridLnkRS17;fmx;JvDlgs;IndySystem;TeeDB;dxSkinValentineRS17;vclib;inetdbbde;DataSnapClient;dxSkinDevExpressStyleRS17;DataSnapProviderClient;DBXSybaseASEDriver;cxBarEditItemRS17;AnyDAC_PhysMSAcc_D17;dxServerModeRS17;cxPivotGridOLAPRS17;cxSchedulerRS17;MetropolisUILiveTile;AnyDAC_PhysSQLITE_D17;dxPSLnksRS17;dxSkinPumpkinRS17;dxPSdxDBOCLnkRS17;cxVerticalGridRS17;dxSkinSpringTimeRS17;vcldsnap;dxSkinDevExpressDarkStyleRS17;DBXDb2Driver;AnyDAC_ComI_D17;DBXOracleDriver;AnyDAC_PhysMSSQL_D17;JvCore;NxDBGridRun_dxe3;vclribbon;AnyDAC_Comp_D17;cxSpreadSheetRS17;dxSkinLiquidSkyRS17;AnyDAC_PhysODBC_D17;fmxase;vcl;dxSkinOffice2007SilverRS17;AnyDAC_PhysPg_D17;IndyIPCommon;DBXMSSQLDriver;CodeSiteExpressPkg;dxPSdxOCLnkRS17;dcldxSkinsCoreRS17;JvAppFrm;AnyDAC_PhysASA_D17;inetdbxpress;webdsnap;NxCollectionRun_dxe3;AnyDAC_PhysOracle_D17;dxSkinCoffeeRS17;JvDocking;adortl;dxSkinscxSchedulerPainterRS17;JvWizards;NxCollectionDsgn_dxe3;frx17;NxCommonDsgn_dxe3;dxtrmdRS17;dxPScxPCProdRS17;AnyDAC_GUIxForms_D17;JvBands;rtl;DbxClientDriver;AnyDAC_PhysTDBX_D17;dxTabbedMDIRS17;dxComnRS17;dxSkinSharpPlusRS17;dxSkinsCoreRS17;dxSkinLondonLiquidSkyRS17;dxdbtrRS17;Tee;JclContainers;NxAddonsRun_dxe3;CPortLibDXE;JvSystem;dxorgcRS17;svnui;dxSkinBlackRS17;JvControls;NxSheetRun_dxe3;IndyProtocols;DBXMySQLDriver;dxLayoutControlRS17;bindcompdbx;TeeUI;JvJans;JvPrintPreview;JvPageComps;JvStdCtrls;JvCustom;dxSkinOffice2007BlueRS17;dxPScxPivotGridLnkRS17;dxSpellCheckerRS17;vcltouch;dxSkinOffice2007GreenRS17;dxSkinSharpRS17;websnap;dxSkinFoggyRS17;dxTileControlRS17;VclSmp;FMXfrxDB17;dxSkinDarkSideRS17;cxPivotGridRS17;DataSnapConnectors;AnyDAC_Phys_D17;fmxobj;SynEdit_RXE3;JclVcl;cxTreeListRS17;dxPSdxFCLnkRS17;dxSkinGlassOceansRS17;frxe17;svn;dxFlowChartRS17;fmxdae;dxSkinsdxNavBarPainterRS17;bdertl;VirtualTreesR;DataSnapIndy10ServerTransport;dxDBXServerModeRS17;dxSkinCaramelRS17;$(DCC_UsePackage)</DCC_UsePackage>
<VerInfo_Locale>1033</VerInfo_Locale>
<DCC_Namespace>Winapi;System.Win;Data.Win;Datasnap.Win;Web.Win;Soap.Win;Xml.Win;Bde;$(DCC_Namespace)</DCC_Namespace>
<VerInfo_Keys>CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments=</VerInfo_Keys>
</PropertyGroup>
<PropertyGroup Condition="'$(Base_Win64)'!=''">
<DCC_UsePackage>cxPivotGridChartRS17;JvMM;dxSkinSevenRS17;dxSkinBlueprintRS17;dxSkinHighContrastRS17;dxSkinOffice2007BlackRS17;dxCoreRS17;cxPageControldxBarPopupMenuRS17;dxSkinXmas2008BlueRS17;dxPSDBTeeChartRS17;JvCrypt;dxPSTeeChartRS17;dxSkinSummer2008RS17;dxPScxSchedulerLnkRS17;dxSkinBlueRS17;dxSkinDarkRoomRS17;DBXInterBaseDriver;DataSnapServer;DataSnapCommon;dxPScxTLLnkRS17;JvNet;dxRibbonRS17;DbxCommonDriver;cxDataRS17;vclimg;dxSkinsdxBarPainterRS17;dxPSdxDBTVLnkRS17;dbxcds;DatasnapConnectorsFreePascal;NxDBGridDsgn_dxe3;dxSkinMoneyTwinsRS17;vcldb;cxExportRS17;dxPSCoreRS17;dxBarExtItemsRS17;dxGDIPlusRS17;dxNavBarRS17;CustomIPTransport;cxLibraryRS17;cxGridRS17;dxSkinOffice2010BlackRS17;dsnap;IndyIPServer;IndyCore;dxSkinMcSkinRS17;dxPScxCommonRS17;AnyDAC_PhysDb2_D17;dxSkinsdxDLPainterRS17;dxSkiniMaginaryRS17;JvDB;dxPScxVGridLnkRS17;dxSkinSevenClassicRS17;dxPScxExtCommonRS17;dxPScxSSLnkRS17;NxGridRun_dxe3;dxSkinLilianRS17;dxPSdxLCLnkRS17;dxSkinOffice2010BlueRS17;NxCommonRun_dxe3;bindcompfmx;dxSkinOffice2010SilverRS17;dbrtl;bindcomp;inetdb;JvPluginSystem;dxBarRS17;DBXOdbcDriver;JvCmp;dxBarDBNavRS17;dxSkinWhiteprintRS17;JvTimeFramework;xmlrtl;dxSkinsdxRibbonPainterRS17;ibxpress;dxDockingRS17;vclactnband;bindengine;soaprtl;dxADOServerModeRS17;bindcompvcl;dxBarExtDBItemsRS17;dxPSPrVwRibbonRS17;vclie;dxSkinOffice2007PinkRS17;cxPageControlRS17;dxSkinscxPCPainterRS17;AnyDAC_PhysADS_D17;AnyDAC_PhysIB_D17;dxmdsRS17;dxSkinTheAsphaltWorldRS17;DBXInformixDriver;dxPsPrVwAdvRS17;NxInspectorRun_dxe3;dxSkinSilverRS17;dxdborRS17;dsnapcon;DBXFirebirdDriver;inet;JvPascalInterpreter;vclx;dxSkinStardustRS17;cxEditorsRS17;DBXSybaseASADriver;NxInspectorDsgn_dxe3;dbexpress;IndyIPClient;AnyDAC_PhysMySQL_D17;cxTreeListdxBarPopupMenuRS17;dxSkinVS2010RS17;NxGridDsgn_dxe3;dxThemeRS17;DBXSqliteDriver;dxPScxGridLnkRS17;fmx;JvDlgs;IndySystem;TeeDB;dxSkinValentineRS17;vclib;DataSnapClient;dxSkinDevExpressStyleRS17;DataSnapProviderClient;DBXSybaseASEDriver;cxBarEditItemRS17;AnyDAC_PhysMSAcc_D17;dxServerModeRS17;cxPivotGridOLAPRS17;cxSchedulerRS17;AnyDAC_PhysSQLITE_D17;dxPSLnksRS17;dxSkinPumpkinRS17;dxPSdxDBOCLnkRS17;cxVerticalGridRS17;dxSkinSpringTimeRS17;vcldsnap;dxSkinDevExpressDarkStyleRS17;DBXDb2Driver;AnyDAC_ComI_D17;DBXOracleDriver;AnyDAC_PhysMSSQL_D17;JvCore;NxDBGridRun_dxe3;AnyDAC_Comp_D17;cxSpreadSheetRS17;dxSkinLiquidSkyRS17;AnyDAC_PhysODBC_D17;fmxase;vcl;dxSkinOffice2007SilverRS17;AnyDAC_PhysPg_D17;IndyIPCommon;DBXMSSQLDriver;dxPSdxOCLnkRS17;dcldxSkinsCoreRS17;JvAppFrm;AnyDAC_PhysASA_D17;inetdbxpress;webdsnap;NxCollectionRun_dxe3;AnyDAC_PhysOracle_D17;dxSkinCoffeeRS17;adortl;dxSkinscxSchedulerPainterRS17;JvWizards;NxCollectionDsgn_dxe3;NxCommonDsgn_dxe3;dxtrmdRS17;dxPScxPCProdRS17;AnyDAC_GUIxForms_D17;JvBands;rtl;DbxClientDriver;AnyDAC_PhysTDBX_D17;dxTabbedMDIRS17;dxComnRS17;dxSkinSharpPlusRS17;dxSkinsCoreRS17;dxSkinLondonLiquidSkyRS17;dxdbtrRS17;Tee;NxAddonsRun_dxe3;JvSystem;dxorgcRS17;dxSkinBlackRS17;JvControls;NxSheetRun_dxe3;IndyProtocols;DBXMySQLDriver;dxLayoutControlRS17;bindcompdbx;TeeUI;JvJans;JvPrintPreview;JvPageComps;JvStdCtrls;JvCustom;dxSkinOffice2007BlueRS17;dxPScxPivotGridLnkRS17;vcltouch;dxSkinOffice2007GreenRS17;dxSkinSharpRS17;websnap;dxSkinFoggyRS17;VclSmp;dxSkinDarkSideRS17;cxPivotGridRS17;DataSnapConnectors;AnyDAC_Phys_D17;fmxobj;SynEdit_RXE3;cxTreeListRS17;dxPSdxFCLnkRS17;dxSkinGlassOceansRS17;dxFlowChartRS17;fmxdae;dxSkinsdxNavBarPainterRS17;DataSnapIndy10ServerTransport;dxDBXServerModeRS17;dxSkinCaramelRS17;$(DCC_UsePackage)</DCC_UsePackage>
@ -193,6 +94,9 @@
<DCC_SymbolReferenceInfo>0</DCC_SymbolReferenceInfo>
<DCC_DebugInformation>0</DCC_DebugInformation>
</PropertyGroup>
<PropertyGroup Condition="'$(Cfg_2_Win32)'!=''">
<VerInfo_Locale>1033</VerInfo_Locale>
</PropertyGroup>
<ItemGroup>
<DelphiCompile Include="$(MainSource)">
<MainSource>MainSource</MainSource>
@ -202,30 +106,10 @@
<FormType>dfm</FormType>
<DesignClass>TWebModule</DesignClass>
</DCCReference>
<DCCReference Include="..\..\sources\MVCFramework.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.RESTClient.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.Router.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.View.Cache.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.View.pas"/>
<DCCReference Include="TestServerControllerU.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.ApplicationSession.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.Session.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.Logger.pas"/>
<DCCReference Include="..\..\lib\delphistompclient\StompClient.pas"/>
<DCCReference Include="..\..\lib\delphistompclient\StompTypes.pas"/>
<DCCReference Include="..\..\sources\RTTIUtilsU.pas"/>
<DCCReference Include="..\..\sources\ObjectsMappers.pas"/>
<DCCReference Include="..\..\sources\DuckListU.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.MessagingController.pas"/>
<DCCReference Include="..\..\samples\commons\BusinessObjectsU.pas"/>
<DCCReference Include="TestServerControllerExceptionU.pas"/>
<DCCReference Include="SpeedMiddlewareU.pas"/>
<DCCReference Include="..\..\sources\uGlobalVars.pas">
<Form>$R *.res</Form>
</DCCReference>
<DCCReference Include="..\..\sources\MVCFramework.Middleware.Authentication.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.Commons.pas"/>
<DCCReference Include="..\..\sources\MVCFramework.SysControllers.pas"/>
<BuildConfiguration Include="Release">
<Key>Cfg_2</Key>
<CfgParent>Base</CfgParent>
@ -282,8 +166,6 @@
<Source Name="MainSource">TestServer.dpr</Source>
</Source>
<Excluded_Packages>
<Excluded_Packages Name="$(BDSBIN)\bcboffice2k230.bpl">Embarcadero C++Builder Office 2000 Servers Package</Excluded_Packages>
<Excluded_Packages Name="$(BDSBIN)\bcbofficexp230.bpl">Embarcadero C++Builder Office XP Servers Package</Excluded_Packages>
<Excluded_Packages Name="$(BDSBIN)\dcloffice2k230.bpl">Microsoft Office 2000 Sample Automation Server Wrapper Components</Excluded_Packages>
<Excluded_Packages Name="$(BDSBIN)\dclofficexp230.bpl">Microsoft Office XP Sample Automation Server Wrapper Components</Excluded_Packages>
</Excluded_Packages>
@ -295,16 +177,7 @@
<Overwrite>true</Overwrite>
</Platform>
</DeployFile>
<DeployClass Name="DependencyModule">
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.dll;.bpl</Extensions>
</Platform>
<Platform Name="OSX32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSDeviceResourceRules"/>
<DeployClass Name="ProjectOSXResource">
<Platform Name="OSX32">
<RemoteDir>Contents\Resources</RemoteDir>
@ -618,7 +491,16 @@
<Operation>1</Operation>
</Platform>
</DeployClass>
<DeployClass Name="ProjectiOSDeviceResourceRules"/>
<DeployClass Name="DependencyModule">
<Platform Name="Win32">
<Operation>0</Operation>
<Extensions>.dll;.bpl</Extensions>
</Platform>
<Platform Name="OSX32">
<Operation>1</Operation>
<Extensions>.dylib</Extensions>
</Platform>
</DeployClass>
<ProjectRoot Platform="iOSDevice64" Name="$(PROJECTNAME).app"/>
<ProjectRoot Platform="Win64" Name="$(PROJECTNAME)"/>
<ProjectRoot Platform="iOSDevice32" Name="$(PROJECTNAME).app"/>
@ -628,11 +510,6 @@
<ProjectRoot Platform="iOSSimulator" Name="$(PROJECTNAME).app"/>
</Deployment>
<Platforms>
<Platform value="Android">False</Platform>
<Platform value="iOSDevice32">False</Platform>
<Platform value="iOSDevice64">False</Platform>
<Platform value="iOSSimulator">False</Platform>
<Platform value="OSX32">False</Platform>
<Platform value="Win32">True</Platform>
<Platform value="Win64">False</Platform>
</Platforms>

Binary file not shown.