MXL : Media eXchange Layer
MXL
Loading...
Searching...
No Matches
test_Provider.cpp
Go to the documentation of this file.
1// SPDX-FileCopyrightText: 2026 Contributors to the Media eXchange Layer project.
2//
3// SPDX-License-Identifier: Apache-2.0
4
5#include <catch2/catch_test_macros.hpp>
6#include "Provider.hpp"
7
8using namespace mxl::lib::fabrics::ofi;
9
17
26
27TEST_CASE("ofi: Provider from string", "[ofi][Provider]")
28{
33
34 REQUIRE_FALSE(providerFromString("invalid").has_value());
35 REQUIRE_FALSE(providerFromString("foo").has_value());
36}
enum mxlFabricsProvider_t mxlFabricsProvider
@ MXL_FABRICS_PROVIDER_VERBS
Definition fabrics.h:50
@ MXL_FABRICS_PROVIDER_TCP
Definition fabrics.h:49
@ MXL_FABRICS_PROVIDER_SHM
Definition fabrics.h:52
@ MXL_FABRICS_PROVIDER_EFA
Definition fabrics.h:51
std::optional< Provider > providerFromString(std::string const &s) noexcept
Parse a provider name string, and return the enum value.
Definition Provider.cpp:49
std::optional< Provider > providerFromAPI(mxlFabricsProvider api) noexcept
Convert between external and internal versions of this type.
Definition Provider.cpp:35
mxlFabricsProvider providerToAPI(Provider provider) noexcept
Convert between external and internal versions of this type.
Definition Provider.cpp:21
TEST_CASE("ofi: Provider enum to API conversion", "[ofi][Provider]")
REQUIRE(timeDelta< 33 '366 '667LL)