Fix int64 -> int64_t in remaining test files, finalize Flatpak manifest
- bignum_tests, script_tests, util_tests, wallet_tests: int64 -> int64_t - Flatpak manifest: use GitHub URLs instead of local paths (Flathub-ready) - Add flathub.json (x86_64 only) - Fill SHA256 hashes for static assets Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,3 @@
|
||||
{
|
||||
"only-arches": ["x86_64"]
|
||||
}
|
||||
@@ -29,18 +29,25 @@ modules:
|
||||
sha256: PLACEHOLDER_UPDATE_AFTER_RELEASE
|
||||
dest-filename: triangles-qt-linux
|
||||
- type: file
|
||||
path: triangles-qt.desktop
|
||||
url: https://raw.githubusercontent.com/SamiAhmed7777/triangles_v5/master/packaging/flatpak/triangles-qt.desktop
|
||||
sha256: f56c4be5870fed6d3f0fb74398241ea909bd3b6f3305fe06ef5f58fba25602ca
|
||||
dest-filename: triangles-qt.desktop
|
||||
- type: file
|
||||
path: ../../src/qt/res/src/triangles.svg
|
||||
url: https://raw.githubusercontent.com/SamiAhmed7777/triangles_v5/master/src/qt/res/src/triangles.svg
|
||||
sha256: c08d0731e209b1941606709d7236526c4334ee52d1cbda2173cad417d6169486
|
||||
dest-filename: triangles.svg
|
||||
- type: file
|
||||
path: ../../src/qt/res/icons/triangles-128.png
|
||||
url: https://raw.githubusercontent.com/SamiAhmed7777/triangles_v5/master/src/qt/res/icons/triangles-128.png
|
||||
sha256: 3a9030b2141ba822059e1d32c29f004c5ed9a4d3c8fc1fba6188201cfdf4ccf5
|
||||
dest-filename: triangles-128.png
|
||||
- type: file
|
||||
path: ../../src/qt/res/icons/triangles.png
|
||||
url: https://raw.githubusercontent.com/SamiAhmed7777/triangles_v5/master/src/qt/res/icons/triangles.png
|
||||
sha256: eebe5b1890c4cf43b8ae3160f81bac93a2a10cd221c99815de9fcd850f225f4e
|
||||
dest-filename: triangles-256.png
|
||||
- type: file
|
||||
path: ../../packaging/appstream/org.cryptographic_triangles.TrianglesQt.metainfo.xml
|
||||
url: https://raw.githubusercontent.com/SamiAhmed7777/triangles_v5/master/packaging/appstream/org.cryptographic_triangles.TrianglesQt.metainfo.xml
|
||||
sha256: dd5ecf9f4916cf0ef3d7ceec763dbbbcf7c4bf806be1e404a96dcfc9423c9fad
|
||||
dest-filename: org.cryptographic_triangles.TrianglesQt.metainfo.xml
|
||||
|
||||
- name: trianglesd
|
||||
buildsystem: simple
|
||||
|
||||
+13
-13
@@ -46,16 +46,16 @@ BOOST_AUTO_TEST_SUITE(bignum_tests)
|
||||
// Let's force this code not to be inlined, in order to actually
|
||||
// test a generic version of the function. This increases the chance
|
||||
// that -ftrapv will detect overflows.
|
||||
NOINLINE void mysetint64(CBigNum& num, int64 n)
|
||||
NOINLINE void mysetint64_t(CBigNum& num, int64_t n)
|
||||
{
|
||||
num.setint64(n);
|
||||
num.setint64_t(n);
|
||||
}
|
||||
|
||||
// For each number, we do 2 tests: one with inline code, then we reset the
|
||||
// value to 0, then the second one with a non-inlined function.
|
||||
BOOST_AUTO_TEST_CASE(bignum_setint64)
|
||||
BOOST_AUTO_TEST_CASE(bignum_setint64_t)
|
||||
{
|
||||
int64 n;
|
||||
int64_t n;
|
||||
|
||||
{
|
||||
n = 0;
|
||||
@@ -63,7 +63,7 @@ BOOST_AUTO_TEST_CASE(bignum_setint64)
|
||||
BOOST_CHECK(num.ToString() == "0");
|
||||
num.setulong(0);
|
||||
BOOST_CHECK(num.ToString() == "0");
|
||||
mysetint64(num, n);
|
||||
mysetint64_t(num, n);
|
||||
BOOST_CHECK(num.ToString() == "0");
|
||||
}
|
||||
{
|
||||
@@ -72,7 +72,7 @@ BOOST_AUTO_TEST_CASE(bignum_setint64)
|
||||
BOOST_CHECK(num.ToString() == "1");
|
||||
num.setulong(0);
|
||||
BOOST_CHECK(num.ToString() == "0");
|
||||
mysetint64(num, n);
|
||||
mysetint64_t(num, n);
|
||||
BOOST_CHECK(num.ToString() == "1");
|
||||
}
|
||||
{
|
||||
@@ -81,7 +81,7 @@ BOOST_AUTO_TEST_CASE(bignum_setint64)
|
||||
BOOST_CHECK(num.ToString() == "-1");
|
||||
num.setulong(0);
|
||||
BOOST_CHECK(num.ToString() == "0");
|
||||
mysetint64(num, n);
|
||||
mysetint64_t(num, n);
|
||||
BOOST_CHECK(num.ToString() == "-1");
|
||||
}
|
||||
{
|
||||
@@ -90,7 +90,7 @@ BOOST_AUTO_TEST_CASE(bignum_setint64)
|
||||
BOOST_CHECK(num.ToString() == "5");
|
||||
num.setulong(0);
|
||||
BOOST_CHECK(num.ToString() == "0");
|
||||
mysetint64(num, n);
|
||||
mysetint64_t(num, n);
|
||||
BOOST_CHECK(num.ToString() == "5");
|
||||
}
|
||||
{
|
||||
@@ -99,25 +99,25 @@ BOOST_AUTO_TEST_CASE(bignum_setint64)
|
||||
BOOST_CHECK(num.ToString() == "-5");
|
||||
num.setulong(0);
|
||||
BOOST_CHECK(num.ToString() == "0");
|
||||
mysetint64(num, n);
|
||||
mysetint64_t(num, n);
|
||||
BOOST_CHECK(num.ToString() == "-5");
|
||||
}
|
||||
{
|
||||
n = std::numeric_limits<int64>::min();
|
||||
n = std::numeric_limits<int64_t>::min();
|
||||
CBigNum num(n);
|
||||
BOOST_CHECK(num.ToString() == "-9223372036854775808");
|
||||
num.setulong(0);
|
||||
BOOST_CHECK(num.ToString() == "0");
|
||||
mysetint64(num, n);
|
||||
mysetint64_t(num, n);
|
||||
BOOST_CHECK(num.ToString() == "-9223372036854775808");
|
||||
}
|
||||
{
|
||||
n = std::numeric_limits<int64>::max();
|
||||
n = std::numeric_limits<int64_t>::max();
|
||||
CBigNum num(n);
|
||||
BOOST_CHECK(num.ToString() == "9223372036854775807");
|
||||
num.setulong(0);
|
||||
BOOST_CHECK(num.ToString() == "0");
|
||||
mysetint64(num, n);
|
||||
mysetint64_t(num, n);
|
||||
BOOST_CHECK(num.ToString() == "9223372036854775807");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -53,7 +53,7 @@ ParseScript(string s)
|
||||
(starts_with(w, "-") && all(string(w.begin()+1, w.end()), is_digit())))
|
||||
{
|
||||
// Number
|
||||
int64 n = atoi64(w);
|
||||
int64_t n = atoi64(w);
|
||||
result << n;
|
||||
}
|
||||
else if (starts_with(w, "0x") && IsHex(string(w.begin()+2, w.end())))
|
||||
|
||||
@@ -199,7 +199,7 @@ BOOST_AUTO_TEST_CASE(util_FormatMoney)
|
||||
|
||||
BOOST_AUTO_TEST_CASE(util_ParseMoney)
|
||||
{
|
||||
int64 ret = 0;
|
||||
int64_t ret = 0;
|
||||
BOOST_CHECK(ParseMoney("0.0", ret));
|
||||
BOOST_CHECK_EQUAL(ret, 0);
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@ BOOST_AUTO_TEST_SUITE(wallet_tests)
|
||||
static CWallet wallet;
|
||||
static vector<COutput> vCoins;
|
||||
|
||||
static void add_coin(int64 nValue, int nAge = 6*24, bool fIsFromMe = false, int nInput=0)
|
||||
static void add_coin(int64_t nValue, int nAge = 6*24, bool fIsFromMe = false, int nInput=0)
|
||||
{
|
||||
static int i;
|
||||
CTransaction* tx = new CTransaction;
|
||||
@@ -56,7 +56,7 @@ static bool equal_sets(CoinSet a, CoinSet b)
|
||||
BOOST_AUTO_TEST_CASE(coin_selection_tests)
|
||||
{
|
||||
static CoinSet setCoinsRet, setCoinsRet2;
|
||||
static int64 nValueRet;
|
||||
static int64_t nValueRet;
|
||||
|
||||
// test multiple times to allow for differences in the shuffle order
|
||||
for (int i = 0; i < RUN_TESTS; i++)
|
||||
|
||||
Reference in New Issue
Block a user