chromium/third_party/openscreen/src/util/trace_logging_unittest.cc

// Copyright 2019 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "util/trace_logging.h"

#include <chrono>
#include <thread>

#include "gmock/gmock.h"
#include "gtest/gtest.h"
#include "platform/test/trace_logging_helpers.h"

namespace openscreen {
namespace {

#if defined(ENABLE_TRACE_LOGGING)
constexpr TraceHierarchyParts kAllParts =;
constexpr TraceHierarchyParts kParentAndRoot =;
constexpr TraceId kEmptyId =;
#endif

_;
AtLeast;
DoAll;
Invoke;

MATCHER_P(EqAsyncEndEvent, expected, "") {}

MATCHER_P(HasSameArguments, expected, "") {}

// All the unit tests below should use TestTraceLoggingPlatform for the
// library's tracing output mock. This is a StrictMock to ensure that, when not
// compiling with ENABLE_TRACE_LOGGING, the mock receives no method calls.
StrictMockLoggingPlatform;

TEST(TraceLoggingTest, MacroCallScopedDoesNotSegFault) {}

TEST(TraceLoggingTest, MacroCallDefaultScopedDoesNotSegFault) {}

TEST(TraceLoggingTest, MacroCallUnscopedDoesNotSegFault) {}

TEST(TraceLoggingTest, MacroVariablesUniquelyNames) {}

TEST(TraceLoggingTest, ExpectTimestampsReflectDelay) {}

TEST(TraceLoggingTest, ExpectErrorsPassedToResult) {}

TEST(TraceLoggingTest, ExpectUnsetTraceIdNotSet) {}

TEST(TraceLoggingTest, ExpectCreationWithIdsToWork) {}

TEST(TraceLoggingTest, ExpectHierarchyToBeApplied) {}

TEST(TraceLoggingTest, ExpectHierarchyToEndAfterScopeWhenSetWithSetter) {}

TEST(TraceLoggingTest, ExpectHierarchyToEndAfterScope) {}

TEST(TraceLoggingTest, ExpectSetHierarchyToApply) {}

TEST(TraceLoggingTest, CheckTraceSupportsArguments) {}

TEST(TraceLoggingTest, CheckTraceCropsArgumentLengths) {}

TEST(TraceLoggingTest, CheckTraceAsyncStartLogsCorrectly) {}

TEST(TraceLoggingTest, CheckTraceAsyncSupportsArguments) {}

TEST(TraceLoggingTest, CheckTraceAsyncStartSetsHierarchy) {}

TEST(TraceLoggingTest, CheckTraceAsyncEndLogsCorrectly) {}

}  // namespace
}  // namespace openscreen