void AccessControlTest::check_remote_datawriter(
        const RTPSParticipantAttributes& participant_attr,
        bool success)
{
    PermissionsHandle* access_handle;
    get_access_handle(participant_attr, &access_handle);

    SecurityException exception;

    WriterProxyData writer_proxy_data(1, 1);
    writer_proxy_data.topicName(eprosima::fastrtps::string_255(topic_name));
    writer_proxy_data.m_qos.m_partition.setNames(partitions);
    bool result = access_plugin.check_remote_datawriter(
        *access_handle,
        domain_id,
        writer_proxy_data,
        exception);

    if (success)
    {
        ASSERT_TRUE(result) << exception.what();
    }
    else
    {
        ASSERT_FALSE(result);
    }
    ASSERT_TRUE(access_plugin.return_permissions_handle(access_handle, exception)) << exception.what();
}
void AccessControlTest::check_remote_datawriter(
        const RTPSParticipantAttributes& participant_attr,
        bool success)
{
    PermissionsHandle* access_handle;
    get_access_handle(participant_attr, &access_handle);

    SecurityException exception;

    WriterProxyData writer_proxy_data(1, 1);
    writer_proxy_data.topicName(eprosima::fastrtps::string_255(topic_name));
    writer_proxy_data.m_qos.m_partition.setNames(partitions);
    bool result = access_plugin.check_remote_datawriter(
        *access_handle,
        domain_id,
        writer_proxy_data,
        exception);

    if (success)
    {
        ASSERT_TRUE(result) << exception.what();
    }
    else
    {
        ASSERT_FALSE(result);
    }
    ASSERT_TRUE(access_plugin.return_permissions_handle(access_handle, exception)) << exception.what();
}