Skip to content

Commit

Permalink
Change backup restore order (#77)
Browse files Browse the repository at this point in the history
* Refs #20936: Increase margins to let Backup Server handle discovery

Signed-off-by: cferreiragonz <carlosferreira@eprosima.com>

* Refs #20936: Run backup tests in CI

Signed-off-by: cferreiragonz <carlosferreira@eprosima.com>

* Refs #20936: Revision

Signed-off-by: cferreiragonz <carlosferreira@eprosima.com>

---------

Signed-off-by: cferreiragonz <carlosferreira@eprosima.com>
  • Loading branch information
cferreiragonz authored Jun 13, 2024
1 parent 6808253 commit 211ed1e
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 38 deletions.
2 changes: 0 additions & 2 deletions test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,6 @@ set(TEST_CASE_LIST)

# Test that are leaky and may fail
set(FAIL_TEST_CASES
test_24_backup
test_25_backup_compatibility
test_26_backup_restore
test_33_superclient_complex
test_99_tcp)
Expand Down
3 changes: 1 addition & 2 deletions test/configuration/test_cases/test_24_backup.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
<DS xmlns="http://www.eprosima.com/XMLSchemas/discovery-server" user_shutdown="false">

<!--
This test verifies that the discovery info is properly serialized and deserialized by a backup server.
This server is created twice by running twice the test_11_BACKUP_server.xml file:
- The first time the discovery data is serialized to a backup file.
Expand All @@ -16,7 +15,7 @@
</servers>

<snapshots file="./test_24_backup.snapshot~">
<snapshot time="5">test_24_backup_snapshot_server</snapshot>
<snapshot time="10">test_24_backup_snapshot_server</snapshot>
</snapshots>

<profiles>
Expand Down
11 changes: 8 additions & 3 deletions test/configuration/test_cases/test_24_backup_1.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,19 @@

<clients>
<client name="client1_server1" profile_name="UDP_client1_server1">
<subscriber /> <!-- defaults to helloworld type -->
<subscriber topic="HelloWorldTopic"/>
<publisher topic="topic1"/>
<publisher topic="topic2"/>
</client>
<client name="client2_server1" profile_name="UDP_client2_server1">
<publisher /> <!-- defaults to helloworld type -->
<publisher topic="HelloWorldTopic"/>
<subscriber topic="topic1"/>
<subscriber topic="topic2"/>
</client>
</clients>

<snapshots file="./test_24_backup_1.snapshot~">
<snapshot time="7">test_24_backup_1_snapshot_clients</snapshot>
<snapshot time="10">test_24_backup_1_snapshot_clients</snapshot>
</snapshots>

<profiles>
Expand Down Expand Up @@ -86,6 +86,11 @@
<dataType>HelloWorld</dataType>
</topic>

<topic profile_name="HelloWorldTopic">
<name>HelloWorldTopic</name>
<dataType>HelloWorld</dataType>
</topic>

</profiles>

</DS>
21 changes: 6 additions & 15 deletions test/configuration/test_cases/test_26_backup_restore.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
<?xml version="1.0" encoding="utf-8"?>
<DS xmlns="http://www.eprosima.com/XMLSchemas/discovery-server" user_shutdown="false">

<!--
This test verifies that the backup server sends matching PDP to its clients after
loading them from the backup file.
-->

<servers>
<server name="server" profile_name="UDP_server"/>
</servers>
Expand All @@ -12,7 +17,7 @@
</clients>

<snapshots file="./test_26_backup_restore.snapshot~">
<snapshot time="2">test_26_backup_restore_snapshot_server</snapshot>
<snapshot time="4">test_26_backup_restore_snapshot_server</snapshot>
</snapshots>

<profiles>
Expand Down Expand Up @@ -63,19 +68,5 @@
<dataType>HelloWorld</dataType>
</topic>

<topic profile_name="topic2">
<name>topic_2</name>
<dataType>HelloWorld</dataType>
</topic>

<types>
<type>
<struct name="HelloWorld">
<member name="index" type="uint32" />
<member name="message" type="string" />
</struct>
</type>
</types>

</profiles>
</DS>
16 changes: 1 addition & 15 deletions test/configuration/test_cases/test_26_backup_restore_1.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
</clients>

<snapshots file="./test_26_backup_restore_1.snapshot~">
<snapshot time="3">test_26_backup_restore_1_snapshot_server</snapshot>
<snapshot time="4">test_26_backup_restore_1_snapshot_server</snapshot>
</snapshots>

<profiles>
Expand Down Expand Up @@ -63,19 +63,5 @@
<dataType>HelloWorld</dataType>
</topic>

<topic profile_name="topic2">
<name>topic_2</name>
<dataType>HelloWorld</dataType>
</topic>

<types>
<type>
<struct name="HelloWorld">
<member name="index" type="uint32" />
<member name="message" type="string" />
</struct>
</type>
</types>

</profiles>
</DS>
2 changes: 1 addition & 1 deletion test/configuration/tests_params.json
Original file line number Diff line number Diff line change
Expand Up @@ -1042,7 +1042,7 @@
"restore":
{
"xml_config_file": "<CONFIG_RELATIVE_PATH>/test_cases/test_26_backup_restore_1.xml",
"creation_time": 4,
"creation_time": 6,
"validation":
{
"count_lines_validation":
Expand Down

0 comments on commit 211ed1e

Please sign in to comment.