PROFINET IO Controller Stack 1.0.0
Modern C++ implementation of a PROFINET IO Controller stack
Loading...
Searching...
No Matches
test_blocksMore.cpp File Reference

Additional unit tests for PROFINET block helpers and parsers. More...

#include <gtest/gtest.h>
#include <array>
#include <cstdint>
#include <string>
#include <tuple>
#include <utility>
#include <vector>
#include "profinet/blocks.h"
#include "profinet/indices.h"
#include "profinet/wire.h"
+ Include dependency graph for test_blocksMore.cpp:

Go to the source code of this file.

Functions

 TEST_F (BlocksMoreTests, BlockHeaderBodyLengthHandlesLengthsBelowTwo)
 
 TEST_F (BlocksMoreTests, BlockHeaderTypeNameHandlesUnknownType)
 
 TEST_F (BlocksMoreTests, SlotInfoToStringFormatsSubslot)
 
 TEST_F (BlocksMoreTests, PeerInfoMacStrFormatsAddress)
 
 TEST_F (BlocksMoreTests, PortInfoMauTypeNameCoversKnownAndUnknownValues)
 
 TEST_F (BlocksMoreTests, PortInfoLinkStateCoversAllBranches)
 
 TEST_F (BlocksMoreTests, InterfaceInfoFormattingHelpers)
 
 TEST_F (BlocksMoreTests, ParseBlockHeaderSupportsOffset)
 
 TEST_F (BlocksMoreTests, ParseBlockHeaderRejectsTruncatedOffset)
 
 TEST_F (BlocksMoreTests, ParseMultipleBlockHeaderParsesAllFields)
 
 TEST_F (BlocksMoreTests, ParseMultipleBlockHeaderRejectsTruncatedInput)
 
 TEST_F (BlocksMoreTests, ParsePdInterfaceDataRealParsesCompleteData)
 
 TEST_F (BlocksMoreTests, ParsePdInterfaceDataRealRejectsMissingChassisLength)
 
 TEST_F (BlocksMoreTests, ParsePdInterfaceDataRealRejectsTruncatedChassis)
 
 TEST_F (BlocksMoreTests, ParsePdInterfaceDataRealRejectsTruncatedMac)
 
 TEST_F (BlocksMoreTests, ParsePdInterfaceDataRealRejectsTruncatedIpConfiguration)
 
 TEST_F (BlocksMoreTests, ParsePdPortDataRealKeepsSuppliedLocationForEmptyInput)
 
 TEST_F (BlocksMoreTests, ParsePdPortDataRealHandlesMissingPortLength)
 
 TEST_F (BlocksMoreTests, ParsePdPortDataRealHandlesMissingPeerCount)
 
 TEST_F (BlocksMoreTests, ParsePdPortDataRealHandlesMissingPeerMac)
 
 TEST_F (BlocksMoreTests, ParsePdPortDataRealHandlesMissingMau)
 
 TEST_F (BlocksMoreTests, ParsePdPortDataRealHandlesIncompleteBoundaries)
 
 TEST_F (BlocksMoreTests, ParsePdPortDataRealHandlesIncompleteLinkState)
 
 TEST_F (BlocksMoreTests, ParsePdPortDataRealHandlesIncompleteMediaType)
 
 TEST_F (BlocksMoreTests, ParsePdRealDataCollectsMultipleHeaderContent)
 
 TEST_F (BlocksMoreTests, ParsePdRealDataSkipsNonMultipleBlock)
 
 TEST_F (BlocksMoreTests, ParsePdRealDataIgnoresMalformedMultipleHeader)
 
 TEST_F (BlocksMoreTests, ParseRealIdentificationDataAcceptsRecognizedHeader)
 
 TEST_F (BlocksMoreTests, ParseRealIdentificationDataFallsBackToRawBody)
 
 TEST_F (BlocksMoreTests, ParseRealIdentificationDataHandlesTruncatedEntry)
 
 TEST_F (BlocksMoreTests, ParsePortStatisticsSupportsOffset)
 
 TEST_F (BlocksMoreTests, ModuleDiffSubmoduleStateNameCoversValues)
 
 TEST_F (BlocksMoreTests, ModuleDiffModuleEvaluatesState)
 
 TEST_F (BlocksMoreTests, ModuleDiffBlockReportsAllMismatches)
 
 TEST_F (BlocksMoreTests, IODWriteMultipleBuilderBuildsEmptyPacket)
 
 TEST_F (BlocksMoreTests, IODWriteMultipleBuilderStoresApiAndMultipleWrites)
 
 TEST_F (BlocksMoreTests, ParseWriteMultipleResponseRejectsShortInput)
 
 TEST_F (BlocksMoreTests, ParseWriteMultipleResponseHandlesMinimalResponse)
 
 TEST_F (BlocksMoreTests, ExpectedSubmoduleDataDescriptionSerializes)
 
 TEST_F (BlocksMoreTests, ExpectedSubmoduleSubmoduleTypeMasksLowBits)
 
 TEST_F (BlocksMoreTests, ExpectedSubmoduleSerializes)
 
 TEST_F (BlocksMoreTests, ExpectedSubmoduleSlotSerializes)
 
 TEST_F (BlocksMoreTests, ExpectedSubmoduleAPISerializes)
 
 TEST_F (BlocksMoreTests, ExpectedSubmoduleBlockReqCreatesSeparateApis)
 
 TEST_F (BlocksMoreTests, ExpectedSubmoduleBlockReqBuildsOutputOnlySubmodule)
 
 TEST_F (BlocksMoreTests, WriteMultipleResultSuccessReflectsStatus)
 
 TEST_F (BlocksMoreTests, ExpectedSubmoduleBlockReqCoversAllSubmoduleTypes)
 
 TEST_F (BlocksMoreTests, ExpectedSubmoduleBlockReqReusesExistingApiAndSlot)
 
 TEST_F (BlocksMoreTests, ParseModuleDiffBlockHandlesHeaderWithoutBody)
 
 TEST_F (BlocksMoreTests, ParseModuleDiffBlockStopsOnTruncatedApi)
 
 TEST_F (BlocksMoreTests, ParseModuleDiffBlockStopsOnTruncatedModule)
 
 TEST_F (BlocksMoreTests, ParsePortStatisticsRejectsTruncatedOffset)
 
 TEST_F (BlocksMoreTests, ParseRealIdentificationDataParsesV11ApiGroupedLayout)
 
 TEST_F (BlocksMoreTests, ParseWriteMultipleResponseParsesSuccessfulResult)
 
 TEST_F (BlocksMoreTests, ParseWriteMultipleResponseParsesFailedResult)
 
 TEST_F (BlocksMoreTests, ParseWriteMultipleResponseStopsOnUnexpectedBlockType)
 
 TEST_F (BlocksMoreTests, IODWriteMultipleBuilderSerializesWriteDetails)
 

Detailed Description

Additional unit tests for PROFINET block helpers and parsers.

Adds branch-oriented coverage for block header helpers, topology data, real identification data, module-difference evaluation, write-multiple serialization/parsing, expected-submodule serialization, and truncated payload handling without duplicating the existing happy-path tests.

Definition in file test_blocksMore.cpp.

Function Documentation

◆ TEST_F() [1/57]

TEST_F ( BlocksMoreTests  ,
BlockHeaderBodyLengthHandlesLengthsBelowTwo   
)
Test:
Verify BlockHeader::BodyLength never underflows for zero or one.

Definition at line 331 of file test_blocksMore.cpp.

References profinet::blocks::BlockHeader::blockLength.

◆ TEST_F() [2/57]

TEST_F ( BlocksMoreTests  ,
BlockHeaderTypeNameHandlesUnknownType   
)
Test:
Verify an unknown block type falls back to its generic name.

Definition at line 340 of file test_blocksMore.cpp.

References profinet::blocks::BlockHeader::blockType.

◆ TEST_F() [3/57]

TEST_F ( BlocksMoreTests  ,
ExpectedSubmoduleAPISerializes   
)
Test:
Verify ExpectedSubmoduleAPI serializes a slot list.

Definition at line 900 of file test_blocksMore.cpp.

References profinet::blocks::ExpectedSubmoduleSlot::api, and profinet::blocks::ExpectedSubmoduleAPI::api.

◆ TEST_F() [4/57]

TEST_F ( BlocksMoreTests  ,
ExpectedSubmoduleBlockReqBuildsOutputOnlySubmodule   
)
Test:
Verify ExpectedSubmoduleBlockReq writes the distinct descriptions for output-only data.

Definition at line 939 of file test_blocksMore.cpp.

References profinet::blocks::ExpectedSubmoduleBlockReq::AddSubmodule(), and profinet::blocks::ExpectedSubmoduleBlockReq::ToBytes().

+ Here is the call graph for this function:

◆ TEST_F() [5/57]

TEST_F ( BlocksMoreTests  ,
ExpectedSubmoduleBlockReqCoversAllSubmoduleTypes   
)
Test:
Verify ExpectedSubmoduleBlockReq creates the correct data description for every submodule type.

Definition at line 966 of file test_blocksMore.cpp.

References profinet::blocks::ExpectedSubmoduleBlockReq::AddSubmodule(), and profinet::blocks::ExpectedSubmoduleBlockReq::ToBytes().

+ Here is the call graph for this function:

◆ TEST_F() [6/57]

TEST_F ( BlocksMoreTests  ,
ExpectedSubmoduleBlockReqCreatesSeparateApis   
)
Test:
Verify ExpectedSubmoduleBlockReq creates separate APIs when API values differ.

Definition at line 915 of file test_blocksMore.cpp.

References profinet::blocks::ExpectedSubmoduleBlockReq::AddSubmodule(), profinet::wire::Reader::Skip(), profinet::blocks::ExpectedSubmoduleBlockReq::ToBytes(), profinet::wire::Reader::U16(), and profinet::wire::Reader::U32().

+ Here is the call graph for this function:

◆ TEST_F() [7/57]

TEST_F ( BlocksMoreTests  ,
ExpectedSubmoduleBlockReqReusesExistingApiAndSlot   
)
Test:
Verify AddSubmodule reuses an existing API and existing slot.

Definition at line 1014 of file test_blocksMore.cpp.

References profinet::blocks::ExpectedSubmoduleBlockReq::AddSubmodule(), profinet::wire::Reader::Skip(), profinet::wire::Reader::SkipTo(), profinet::blocks::ExpectedSubmoduleBlockReq::ToBytes(), and profinet::wire::Reader::U16().

+ Here is the call graph for this function:

◆ TEST_F() [8/57]

TEST_F ( BlocksMoreTests  ,
ExpectedSubmoduleDataDescriptionSerializes   
)
Test:
Verify ExpectedSubmoduleDataDescription serializes its six wire bytes.

Definition at line 840 of file test_blocksMore.cpp.

References profinet::blocks::ExpectedSubmoduleDataDescription::dataDescription.

◆ TEST_F() [9/57]

TEST_F ( BlocksMoreTests  ,
ExpectedSubmoduleSerializes   
)
Test:
Verify ExpectedSubmodule serializes its header and descriptions.

Definition at line 870 of file test_blocksMore.cpp.

References profinet::blocks::ExpectedSubmoduleDataDescription::dataDescription, and profinet::blocks::ExpectedSubmodule::subslotNumber.

◆ TEST_F() [10/57]

TEST_F ( BlocksMoreTests  ,
ExpectedSubmoduleSlotSerializes   
)
Test:
Verify ExpectedSubmoduleSlot serializes a slot containing a submodule.

Definition at line 885 of file test_blocksMore.cpp.

References profinet::blocks::ExpectedSubmoduleSlot::api, and profinet::blocks::ExpectedSubmodule::subslotNumber.

◆ TEST_F() [11/57]

TEST_F ( BlocksMoreTests  ,
ExpectedSubmoduleSubmoduleTypeMasksLowBits   
)
Test:
Verify ExpectedSubmodule::SubmoduleType masks properties correctly.

Definition at line 860 of file test_blocksMore.cpp.

References profinet::blocks::ExpectedSubmodule::submoduleProperties.

◆ TEST_F() [12/57]

TEST_F ( BlocksMoreTests  ,
InterfaceInfoFormattingHelpers   
)
Test:
Verify InterfaceInfo formatting helpers expose all stored addresses.

Definition at line 409 of file test_blocksMore.cpp.

References profinet::blocks::InterfaceInfo::chassisId.

◆ TEST_F() [13/57]

TEST_F ( BlocksMoreTests  ,
IODWriteMultipleBuilderBuildsEmptyPacket   
)
Test:
Verify IODWriteMultipleBuilder can build an empty write list.

Definition at line 793 of file test_blocksMore.cpp.

References profinet::blocks::IODWriteMultipleBuilder::Build(), profinet::wire::Reader::U16(), and profinet::blocks::IODWriteMultipleBuilder::writeMultipleBlockType.

+ Here is the call graph for this function:

◆ TEST_F() [14/57]

TEST_F ( BlocksMoreTests  ,
IODWriteMultipleBuilderSerializesWriteDetails   
)
Test:
Verify IODWriteMultipleBuilder serializes multiple writes with distinct sequence numbers.

Definition at line 1226 of file test_blocksMore.cpp.

References profinet::blocks::IODWriteMultipleBuilder::AddWrite(), profinet::blocks::IODWriteMultipleBuilder::Build(), profinet::wire::Reader::SkipTo(), profinet::wire::Reader::U16(), and profinet::blocks::IODWriteMultipleBuilder::writeMultipleBlockType.

+ Here is the call graph for this function:

◆ TEST_F() [15/57]

TEST_F ( BlocksMoreTests  ,
IODWriteMultipleBuilderStoresApiAndMultipleWrites   
)
Test:
Verify AddWrite accepts a custom API and multiple records.

Definition at line 806 of file test_blocksMore.cpp.

References profinet::blocks::IODWriteMultipleBuilder::AddWrite(), profinet::blocks::IODWriteMultipleBuilder::Build(), profinet::wire::Reader::Skip(), profinet::wire::Reader::U16(), and profinet::WRITE_MULTIPLE.

+ Here is the call graph for this function:

◆ TEST_F() [16/57]

TEST_F ( BlocksMoreTests  ,
ModuleDiffBlockReportsAllMismatches   
)

◆ TEST_F() [17/57]

TEST_F ( BlocksMoreTests  ,
ModuleDiffModuleEvaluatesState   
)
Test:
Verify ModuleDiffModule evaluates proper and improper module states.

Definition at line 755 of file test_blocksMore.cpp.

◆ TEST_F() [18/57]

TEST_F ( BlocksMoreTests  ,
ModuleDiffSubmoduleStateNameCoversValues   
)
Test:
Verify ModuleDiffSubmodule state decoding covers representative and unknown values.

Definition at line 738 of file test_blocksMore.cpp.

References profinet::blocks::ModuleDiffSubmodule::IsOk(), profinet::blocks::ModuleDiffSubmodule::StateName(), profinet::SUBMODULE_STATE_OK, profinet::SUBMODULE_STATE_WRONG_SUBMODULE, and profinet::blocks::ModuleDiffSubmodule::submoduleState.

+ Here is the call graph for this function:

◆ TEST_F() [19/57]

TEST_F ( BlocksMoreTests  ,
ParseBlockHeaderRejectsTruncatedOffset   
)
Test:
Verify ParseBlockHeader rejects a truncated header at a non-zero offset.

Definition at line 437 of file test_blocksMore.cpp.

References profinet::blocks::ParseBlockHeader().

+ Here is the call graph for this function:

◆ TEST_F() [20/57]

TEST_F ( BlocksMoreTests  ,
ParseBlockHeaderSupportsOffset   
)
Test:
Verify ParseBlockHeader accepts a non-zero starting offset.

Definition at line 421 of file test_blocksMore.cpp.

References profinet::blocks::ParseBlockHeader().

+ Here is the call graph for this function:

◆ TEST_F() [21/57]

TEST_F ( BlocksMoreTests  ,
ParseModuleDiffBlockHandlesHeaderWithoutBody   
)
Test:
Verify ParseModuleDiffBlock returns an empty block when no API count is present.

Definition at line 1035 of file test_blocksMore.cpp.

References profinet::blocks::ParseModuleDiffBlock().

+ Here is the call graph for this function:

◆ TEST_F() [22/57]

TEST_F ( BlocksMoreTests  ,
ParseModuleDiffBlockStopsOnTruncatedApi   
)
Test:
Verify ParseModuleDiffBlock stops safely when an API header is truncated.

Definition at line 1045 of file test_blocksMore.cpp.

References profinet::blocks::ParseModuleDiffBlock(), profinet::wire::PutU16(), and profinet::wire::PutU32().

+ Here is the call graph for this function:

◆ TEST_F() [23/57]

TEST_F ( BlocksMoreTests  ,
ParseModuleDiffBlockStopsOnTruncatedModule   
)
Test:
Verify ParseModuleDiffBlock stops safely when a module header is truncated.

Definition at line 1058 of file test_blocksMore.cpp.

References profinet::blocks::ParseModuleDiffBlock(), profinet::wire::PutU16(), and profinet::wire::PutU32().

+ Here is the call graph for this function:

◆ TEST_F() [24/57]

TEST_F ( BlocksMoreTests  ,
ParseMultipleBlockHeaderParsesAllFields   
)
Test:
Verify ParseMultipleBlockHeader decodes padding, API, slot and subslot.

Definition at line 444 of file test_blocksMore.cpp.

References profinet::blocks::ParseMultipleBlockHeader(), profinet::wire::PutU16(), and profinet::wire::PutU32().

+ Here is the call graph for this function:

◆ TEST_F() [25/57]

TEST_F ( BlocksMoreTests  ,
ParseMultipleBlockHeaderRejectsTruncatedInput   
)
Test:
Verify ParseMultipleBlockHeader rejects truncated input.

Definition at line 461 of file test_blocksMore.cpp.

References profinet::blocks::ParseMultipleBlockHeader().

+ Here is the call graph for this function:

◆ TEST_F() [26/57]

TEST_F ( BlocksMoreTests  ,
ParsePdInterfaceDataRealParsesCompleteData   
)
Test:
Verify ParsePdInterfaceDataReal decodes chassis, MAC and IP configuration.

Definition at line 467 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdInterfaceDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [27/57]

TEST_F ( BlocksMoreTests  ,
ParsePdInterfaceDataRealRejectsMissingChassisLength   
)
Test:
Verify ParsePdInterfaceDataReal rejects a missing chassis-length byte.

Definition at line 481 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdInterfaceDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [28/57]

TEST_F ( BlocksMoreTests  ,
ParsePdInterfaceDataRealRejectsTruncatedChassis   
)
Test:
Verify ParsePdInterfaceDataReal rejects a truncated chassis identifier.

Definition at line 487 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdInterfaceDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [29/57]

TEST_F ( BlocksMoreTests  ,
ParsePdInterfaceDataRealRejectsTruncatedIpConfiguration   
)
Test:
Verify ParsePdInterfaceDataReal rejects truncated IP configuration.

Definition at line 501 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdInterfaceDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [30/57]

TEST_F ( BlocksMoreTests  ,
ParsePdInterfaceDataRealRejectsTruncatedMac   
)
Test:
Verify ParsePdInterfaceDataReal rejects a truncated MAC address.

Definition at line 493 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdInterfaceDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [31/57]

TEST_F ( BlocksMoreTests  ,
ParsePdPortDataRealHandlesIncompleteBoundaries   
)
Test:
Verify ParsePdPortDataReal handles an incomplete boundary section.

Definition at line 578 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdPortDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [32/57]

TEST_F ( BlocksMoreTests  ,
ParsePdPortDataRealHandlesIncompleteLinkState   
)
Test:
Verify ParsePdPortDataReal handles an incomplete link-state section.

Definition at line 591 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdPortDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [33/57]

TEST_F ( BlocksMoreTests  ,
ParsePdPortDataRealHandlesIncompleteMediaType   
)
Test:
Verify ParsePdPortDataReal handles an incomplete media-type section.

Definition at line 608 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdPortDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [34/57]

TEST_F ( BlocksMoreTests  ,
ParsePdPortDataRealHandlesMissingMau   
)
Test:
Verify ParsePdPortDataReal returns defaults when MAU data is absent.

Definition at line 565 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdPortDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [35/57]

TEST_F ( BlocksMoreTests  ,
ParsePdPortDataRealHandlesMissingPeerCount   
)
Test:
Verify ParsePdPortDataReal handles a port ID without peer-count data.

Definition at line 537 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdPortDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [36/57]

TEST_F ( BlocksMoreTests  ,
ParsePdPortDataRealHandlesMissingPeerMac   
)
Test:
Verify ParsePdPortDataReal handles a peer record without a MAC address.

Definition at line 548 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdPortDataReal(), and profinet::blocks::PeerInfo::portId.

+ Here is the call graph for this function:

◆ TEST_F() [37/57]

TEST_F ( BlocksMoreTests  ,
ParsePdPortDataRealHandlesMissingPortLength   
)
Test:
Verify ParsePdPortDataReal handles a payload ending after slot/subslot.

Definition at line 526 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdPortDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [38/57]

TEST_F ( BlocksMoreTests  ,
ParsePdPortDataRealKeepsSuppliedLocationForEmptyInput   
)
Test:
Verify ParsePdPortDataReal handles a payload containing no fields.

Definition at line 516 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdPortDataReal().

+ Here is the call graph for this function:

◆ TEST_F() [39/57]

TEST_F ( BlocksMoreTests  ,
ParsePdRealDataCollectsMultipleHeaderContent   
)
Test:
Verify ParsePdRealData collects nested blocks and raw block data.

Definition at line 621 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdRealData().

+ Here is the call graph for this function:

◆ TEST_F() [40/57]

TEST_F ( BlocksMoreTests  ,
ParsePdRealDataIgnoresMalformedMultipleHeader   
)
Test:
Verify ParsePdRealData survives a truncated multiple-header body.

Definition at line 662 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdRealData().

+ Here is the call graph for this function:

◆ TEST_F() [41/57]

TEST_F ( BlocksMoreTests  ,
ParsePdRealDataSkipsNonMultipleBlock   
)
Test:
Verify ParsePdRealData ignores a non-multiple top-level block safely.

Definition at line 650 of file test_blocksMore.cpp.

References profinet::blocks::ParsePdRealData().

+ Here is the call graph for this function:

◆ TEST_F() [42/57]

TEST_F ( BlocksMoreTests  ,
ParsePortStatisticsRejectsTruncatedOffset   
)
Test:
Verify ParsePortStatistics returns nullopt for a truncated payload at an offset.

Definition at line 1072 of file test_blocksMore.cpp.

References profinet::blocks::ParsePortStatistics().

+ Here is the call graph for this function:

◆ TEST_F() [43/57]

TEST_F ( BlocksMoreTests  ,
ParsePortStatisticsSupportsOffset   
)
Test:
Verify ParsePortStatistics honors a non-zero offset.

Definition at line 718 of file test_blocksMore.cpp.

References profinet::blocks::ParsePortStatistics(), profinet::wire::PutU16(), and profinet::wire::PutU32().

+ Here is the call graph for this function:

◆ TEST_F() [44/57]

TEST_F ( BlocksMoreTests  ,
ParseRealIdentificationDataAcceptsRecognizedHeader   
)
Test:
Verify ParseRealIdentificationData accepts a recognized v1.1 header.

Definition at line 673 of file test_blocksMore.cpp.

References profinet::blocks::ParseRealIdentificationData().

+ Here is the call graph for this function:

◆ TEST_F() [45/57]

TEST_F ( BlocksMoreTests  ,
ParseRealIdentificationDataFallsBackToRawBody   
)
Test:
Verify ParseRealIdentificationData falls back to raw v1.0 bodies.

Definition at line 688 of file test_blocksMore.cpp.

References profinet::blocks::ParseRealIdentificationData().

+ Here is the call graph for this function:

◆ TEST_F() [46/57]

TEST_F ( BlocksMoreTests  ,
ParseRealIdentificationDataHandlesTruncatedEntry   
)
Test:
Verify ParseRealIdentificationData rejects an incomplete slot entry safely.

Definition at line 702 of file test_blocksMore.cpp.

References profinet::blocks::ParseRealIdentificationData(), profinet::wire::PutU16(), and profinet::wire::PutU32().

+ Here is the call graph for this function:

◆ TEST_F() [47/57]

TEST_F ( BlocksMoreTests  ,
ParseRealIdentificationDataParsesV11ApiGroupedLayout   
)
Test:
Verify ParseRealIdentificationData parses the API-grouped v1.1 layout.

Definition at line 1081 of file test_blocksMore.cpp.

References profinet::blocks::ParseRealIdentificationData().

+ Here is the call graph for this function:

◆ TEST_F() [48/57]

TEST_F ( BlocksMoreTests  ,
ParseWriteMultipleResponseHandlesMinimalResponse   
)
Test:
Verify ParseWriteMultipleResponse ignores an empty 64-byte response.

Definition at line 831 of file test_blocksMore.cpp.

References profinet::blocks::ParseWriteMultipleResponse().

+ Here is the call graph for this function:

◆ TEST_F() [49/57]

TEST_F ( BlocksMoreTests  ,
ParseWriteMultipleResponseParsesFailedResult   
)
Test:
Verify ParseWriteMultipleResponse preserves a failed write status.

Definition at line 1155 of file test_blocksMore.cpp.

References profinet::blocks::ParseWriteMultipleResponse().

+ Here is the call graph for this function:

◆ TEST_F() [50/57]

TEST_F ( BlocksMoreTests  ,
ParseWriteMultipleResponseParsesSuccessfulResult   
)
Test:
Verify ParseWriteMultipleResponse decodes a successful result block.

Definition at line 1110 of file test_blocksMore.cpp.

References profinet::blocks::ParseWriteMultipleResponse().

+ Here is the call graph for this function:

◆ TEST_F() [51/57]

TEST_F ( BlocksMoreTests  ,
ParseWriteMultipleResponseRejectsShortInput   
)
Test:
Verify ParseWriteMultipleResponse safely rejects undersized input.

Definition at line 824 of file test_blocksMore.cpp.

References profinet::blocks::ParseWriteMultipleResponse().

+ Here is the call graph for this function:

◆ TEST_F() [52/57]

TEST_F ( BlocksMoreTests  ,
ParseWriteMultipleResponseStopsOnUnexpectedBlockType   
)
Test:
Verify ParseWriteMultipleResponse stops when a nested block has the wrong type.

Definition at line 1198 of file test_blocksMore.cpp.

References profinet::blocks::ParseWriteMultipleResponse().

+ Here is the call graph for this function:

◆ TEST_F() [53/57]

TEST_F ( BlocksMoreTests  ,
PeerInfoMacStrFormatsAddress   
)
Test:
Verify PeerInfo::MacStr delegates to the canonical MAC formatter.

Definition at line 355 of file test_blocksMore.cpp.

References profinet::blocks::PeerInfo::macAddress.

◆ TEST_F() [54/57]

TEST_F ( BlocksMoreTests  ,
PortInfoLinkStateCoversAllBranches   
)
Test:
Verify every link-state switch branch, including the fallback.

Definition at line 392 of file test_blocksMore.cpp.

References profinet::blocks::PortInfo::LinkState(), and profinet::blocks::PortInfo::linkStateLink.

+ Here is the call graph for this function:

◆ TEST_F() [55/57]

TEST_F ( BlocksMoreTests  ,
PortInfoMauTypeNameCoversKnownAndUnknownValues   
)
Test:
Verify every documented MAU-name mapping and the unknown fallback.

Definition at line 363 of file test_blocksMore.cpp.

References profinet::blocks::PortInfo::mauType, and profinet::blocks::PortInfo::MauTypeName().

+ Here is the call graph for this function:

◆ TEST_F() [56/57]

TEST_F ( BlocksMoreTests  ,
SlotInfoToStringFormatsSubslot   
)
Test:
Verify SlotInfo::ToString uses the documented hexadecimal subslot format.

Definition at line 347 of file test_blocksMore.cpp.

References profinet::blocks::SlotInfo::slot.

◆ TEST_F() [57/57]

TEST_F ( BlocksMoreTests  ,
WriteMultipleResultSuccessReflectsStatus   
)
Test:
Verify WriteMultipleResult::Success distinguishes zero and non-zero status.

Definition at line 951 of file test_blocksMore.cpp.

References profinet::blocks::WriteMultipleResult::status, and profinet::blocks::WriteMultipleResult::Success().

+ Here is the call graph for this function: