Skip to content

Commit

Permalink
Updated BoldTest cases due to Bold changes. #20
Browse files Browse the repository at this point in the history
  • Loading branch information
bero committed Dec 6, 2024
1 parent 8e82283 commit 04486ce
Show file tree
Hide file tree
Showing 7 changed files with 6 additions and 16 deletions.
2 changes: 1 addition & 1 deletion Source/BoldTestCases/Code/ObjectSpace/aniv_1.pas
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ interface
BoldUMLModelLink, BoldUMLXMILink, DB,
BoldAbstractDatabaseAdapter, BoldAbstractPersistenceHandleDB,
BoldDatabaseAdapterUniDAC, DBAccess, Uni, PostgreSQLUniProvider,
InterBaseUniProvider, DAScript, UniScript, System.Actions;
DAScript, UniScript, System.Actions;

type
Tdm_aniv_test1 = class(TDataModule)
Expand Down
6 changes: 0 additions & 6 deletions Source/BoldTestCases/Code/ObjectSpace/aniv_FLS.pas
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,6 @@ TAniv_Regions = class(TLocalTestCase)
procedure ParentExpansion;
end;

{$IFNDEF BOLD_NO_QUERIES}
TDummyLockHolder = class;

TAniv_LockHandler = class(TLocalTestCase)
Expand Down Expand Up @@ -135,7 +134,6 @@ TDummyLockHolder = class(TBoldLockHolder)
procedure GetPropagationEvents(EventList: TStringList); override;
function EnsureLocks: Boolean; override;
end;
{$ENDIF}

var
dmAnivFLS: TdmAnivFLS;
Expand Down Expand Up @@ -707,7 +705,6 @@ class function TAniv_Regions.Suite: ITestSuite;
SetCommentForTest(Result, 'ParentExpansion', '');
end;

{$IFNDEF BOLD_NO_QUERIES}
{ TAniv_LockHandler }

procedure TAniv_LockHandler.DeletingObjects;
Expand Down Expand Up @@ -1202,16 +1199,13 @@ procedure TAniv_FLS_Various.TearDown;
FreeAndNil(LockHolder);
FreeAndNil(dmAnivFLS);
end;
{$ENDIF}

initialization
TestGlobal.RegisterTestCase(TAniv_RegionDefinitions);
TestGlobal.RegisterTestCase(TAniv_Regions);
{$IFNDEF BOLD_NO_QUERIES}
TestGlobal.RegisterTestCase(TAniv_FLS_Various);
TestGlobal.RegisterTestCase(TAniv_LockHandler);
TestGlobal.RegisterTestCase(TAniv_LockHolder);
TestGlobal.RegisterTestCase(TAniv_LockingHandle);
{$ENDIF}
end.

2 changes: 1 addition & 1 deletion Source/BoldTestCases/Code/Propagator/maanClientHandler.pas
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ procedure TMaan_TestCaseClientHandler.SetUp;
for i:= 0 to NO_CLIENTS do
begin
if not Assigned(fClientHandler) then
fClientHandler := TTestableClientHandler.Create;
fClientHandler := TTestableClientHandler.Create(fClientHandler);
if not Assigned(ListenerIntf) then
ListenerIntf := TTestBoldListener.Create;
fClientidentifierString := Format('TestClient%d', [i]);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -351,7 +351,7 @@ procedure TTestCase_PriorityListEnlister.SetUp;
fOutputQueueHandler := TTestableOutputQueueHandler.Create;
fPriorityListEnlister := TTestablePriorityListEnlister.Create;
fNotificationList := TList.Create;
fClientHandler := TBoldClientHandler.Create;
fClientHandler := TBoldClientHandler.Create(fClientHandler);
(fPriorityListEnlister as TTestablePriorityListEnlister).PriorityList.OnHeadChanged := OnPriorityChanged;
// register clients 1 & 2
RegisterClients;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ procedure TTestCase_ClientNotifier.SetUp;
fListenerThread.Resume;
fListenerThread.WaitUntilReady(INFINITE);
fPriorityListEnlister := TMyPriorityListEnlister.Create;
fClientHandler := TBoldClientHandler.Create;
fClientHandler := TBoldClientHandler.Create(fClientHandler);
fClientNotifierHandler := TBoldClientNotifierHandler.Create(1, fClientHandler, fPriorityListEnlister.PriorityList, true);
end;

Expand Down Expand Up @@ -154,7 +154,7 @@ procedure TTestCase_ClientNotifierHandler.SetUp;
fListenerThread := TTestListenerThread2.Create(true, 4);
fListenerThread.Resume;
fListenerThread.WaitUntilReady(INFINITE);
fClientHandler:= TBoldClientHandler.Create;
fClientHandler:= TBoldClientHandler.Create(fClientHandler);
fPriorityListEnlister:= TMyPriorityListEnlister.Create;
fOutputQueueHandler:= TMyOutputQueueHandler.Create;
fClientNotifierHandler:= TBoldClientNotifierHandler.Create(15, fClientHandler, fPriorityListEnlister.Prioritylist, true);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ procedure TTestCase_PropagatorCleanUp.SetUp;
fPropagator := TDummyAdvancedPropagator.Create;
fPropagator.Initialize;
(TPropagatorServerTest.Instance as TPropagatorServerTest).fAdvancedPropagator := fPropagator;
fClientHandler := TTestableClientHandler.Create;
fClientHandler := TTestableClientHandler.Create(fClientHandler);
fEventQueue := TBoldThreadSafeObjectQueue.Create('TSQ-Testcase/Cleanup');
fPropagator.fClientHandlerTest := fClienthandler;
fCleanUpSubscriber := TBoldCleanUpSubscriber.Create(fClientHandler);
Expand Down
4 changes: 0 additions & 4 deletions Source/BoldTestCases/Framework/UnitTest/BoldUnitTestReg.pas
Original file line number Diff line number Diff line change
Expand Up @@ -46,11 +46,9 @@ implementation
maan_PropagatorLockingSupport,
maanBoldSnooperHandle,
aniv_1,
{$IFNDEF BOLD_NO_QUERIES}
aniv_FLS,
{$IFNDEF OXML}
aniv_xml,
{$ENDIF}
{$ENDIF}
aniv_temporal,
dmjehoBoldTest,
Expand Down Expand Up @@ -136,15 +134,13 @@ procedure RegisterObjectSpaceTestCases;
TAniv_PrioQueue.Suite,
TAniv_Various.Suite,
TAniv_fmDistributable.Suite]),
{$IFNDEF BOLD_NO_QUERIES}
TTestSuite.Create('FullLockingSupport testcases',
[TAniv_RegionDefinitions.Suite,
TAniv_Regions.Suite,
TAniv_LockHandler.Suite,
TAniv_FLS_Various.Suite,
TAniv_LockHolder.Suite,
TAniv_LockingHandle.Suite]),
{$ENDIF}
TAniv_temporal1.Suite,
{$IFNDEF OXML} // TODO update TAniv_XMLStreaming to work with OXML
TAniv_XMLStreaming.Suite,
Expand Down

0 comments on commit 04486ce

Please sign in to comment.