Bitcoin Core 28.99.0
P2P Digital Currency
ipc_test.h
Go to the documentation of this file.
1// Copyright (c) 2023 The Bitcoin Core developers
2// Distributed under the MIT software license, see the accompanying
3// file COPYING or http://www.opensource.org/licenses/mit-license.php.
4
5#ifndef BITCOIN_TEST_IPC_TEST_H
6#define BITCOIN_TEST_IPC_TEST_H
7
9#include <univalue.h>
10#include <util/fs.h>
11#include <validation.h>
12
14{
15public:
16 int add(int a, int b) { return a + b; }
20 std::vector<char> passVectorChar(std::vector<char> v) { return v; }
22};
23
24void IpcPipeTest();
26void IpcSocketTest(const fs::path& datadir);
27
28#endif // BITCOIN_TEST_IPC_TEST_H
An outpoint - a combination of a transaction hash and an index n into its vout.
Definition: transaction.h:29
CTransactionRef passTransaction(CTransactionRef t)
Definition: ipc_test.h:19
std::vector< char > passVectorChar(std::vector< char > v)
Definition: ipc_test.h:20
BlockValidationState passBlockState(BlockValidationState s)
Definition: ipc_test.h:21
COutPoint passOutPoint(COutPoint o)
Definition: ipc_test.h:17
int add(int a, int b)
Definition: ipc_test.h:16
UniValue passUniValue(UniValue v)
Definition: ipc_test.h:18
Path class wrapper to block calls to the fs::path(std::string) implicit constructor and the fs::path:...
Definition: fs.h:33
void IpcSocketTest(const fs::path &datadir)
Test ipc::Process bind() and connect() methods connecting over a unix socket.
Definition: ipc_test.cpp:150
void IpcPipeTest()
Unit test that tests execution of IPC calls without actually creating a separate process.
Definition: ipc_test.cpp:54
void IpcSocketPairTest()
Test ipc::Protocol connect() and serve() methods connecting over a socketpair.
Definition: ipc_test.cpp:130
std::shared_ptr< const CTransaction > CTransactionRef
Definition: transaction.h:423