Files

47 lines
1.4 KiB
C++
Raw Permalink Normal View History

2017-11-09 19:34:51 +01:00
/*
* This file is part of the Flowee project
2021-06-20 22:44:44 +02:00
* Copyright (C) 2016 Tom Zander <tom@flowee.org>
2017-11-09 19:34:51 +01:00
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
2018-01-16 10:47:52 +00:00
#ifndef FLOWEE_TEST_TRANSACTION_UTILS_H
#define FLOWEE_TEST_TRANSACTION_UTILS_H
2017-07-23 12:37:49 +02:00
#include <vector>
#include <string>
2017-07-23 12:37:49 +02:00
class CScript;
2017-04-22 00:57:16 +09:00
struct CMutableTransaction;
class CTransaction;
namespace TxUtils {
void RandomScript(CScript &script);
void RandomInScript(CScript &script);
2016-11-07 16:22:29 +01:00
enum RandomTransactionType {
SingleOutput,
AnyOutputCount
};
void RandomTransaction(CMutableTransaction &tx, RandomTransactionType single);
2016-09-15 22:48:59 +02:00
2017-07-23 12:37:49 +02:00
// create one transaction and repeat it until it fills up the space.
std::vector<CTransaction> transactionsForBlock(int minSize);
std::string FormatScript(const CScript& script);
}
#endif