mirror of
https://github.com/Such-Software/hash-wallet.git
synced 2026-12-04 12:34:14 +01:00
This reverts commit e37f478588.
This commit is contained in:
@@ -582,8 +582,8 @@ packages:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
path: "impls/monero.dart"
|
||||
ref: c157cb82973b05d1226b39b4d8de0bec4aa10000
|
||||
resolved-ref: c157cb82973b05d1226b39b4d8de0bec4aa10000
|
||||
ref: "411e8a1cdb3f4c2812d83f28c335d2a4eb18bd29"
|
||||
resolved-ref: "411e8a1cdb3f4c2812d83f28c335d2a4eb18bd29"
|
||||
url: "https://github.com/mrcyjanek/monero_c"
|
||||
source: git
|
||||
version: "0.0.0"
|
||||
|
||||
@@ -26,7 +26,7 @@ dependencies:
|
||||
monero:
|
||||
git:
|
||||
url: https://github.com/mrcyjanek/monero_c
|
||||
ref: c157cb82973b05d1226b39b4d8de0bec4aa10000
|
||||
ref: 411e8a1cdb3f4c2812d83f28c335d2a4eb18bd29
|
||||
path: impls/monero.dart
|
||||
mutex: ^3.1.0
|
||||
ledger_flutter_plus: ^1.4.1
|
||||
@@ -54,6 +54,7 @@ flutter:
|
||||
# be modified. They are used by the tooling to maintain consistency when
|
||||
# adding or updating assets for this project.
|
||||
|
||||
|
||||
# To add assets to your plugin package, add an assets section, like this:
|
||||
# assets:
|
||||
# - images/a_dot_burr.jpeg
|
||||
|
||||
@@ -18,7 +18,7 @@ import 'utils/setup_monero_c.dart';
|
||||
Future<void> main() async {
|
||||
group("MoneroWalletService Tests", () {
|
||||
late MoneroWalletService walletService;
|
||||
File? moneroCBinary;
|
||||
late File moneroCBinary;
|
||||
|
||||
setUpAll(() async {
|
||||
await initDb(pathOverride: './test/data/db');
|
||||
@@ -34,7 +34,7 @@ Future<void> main() async {
|
||||
|
||||
tearDownAll(() {
|
||||
Directory('./test/data').deleteSync(recursive: true);
|
||||
moneroCBinary!.deleteSync();
|
||||
moneroCBinary.deleteSync();
|
||||
});
|
||||
|
||||
group("Create wallet", () {
|
||||
|
||||
@@ -1,27 +1,16 @@
|
||||
import 'dart:io';
|
||||
import 'package:path/path.dart' as p;
|
||||
|
||||
File getMoneroCBinary() {
|
||||
final baseDir = Directory('../scripts/monero_c/release');
|
||||
|
||||
final versionDir =
|
||||
baseDir.listSync().whereType<Directory>().map((d) => d.path).firstWhere(
|
||||
(path) => p.basename(path).startsWith('v'),
|
||||
);
|
||||
|
||||
if (Platform.isWindows) {
|
||||
return File(p.join(
|
||||
versionDir, 'x86_64-w64-mingw32', 'libmonero_wallet2_api_c.dll'));
|
||||
}
|
||||
if (Platform.isMacOS) {
|
||||
return File(p.join(versionDir, 'macos', 'libmonero_wallet2_api_c.dylib'));
|
||||
}
|
||||
return File(
|
||||
p.join(versionDir, 'x86_64-linux-gnu', 'libmonero_wallet2_api_c.so'));
|
||||
if (Platform.isWindows)
|
||||
return File(
|
||||
'../scripts/monero_c/release/monero/x86_64-w64-mingw32_libwallet2_api_c.dll');
|
||||
if (Platform.isMacOS) return File('../macos/monero_libwallet2_api_c.dylib');
|
||||
return File('../scripts/monero_c/release/monero/x86_64-linux-gnu_libwallet2_api_c.so');
|
||||
}
|
||||
|
||||
String get moneroCBinaryName {
|
||||
if (Platform.isWindows) return "libmonero_wallet2_api_c.dll";
|
||||
if (Platform.isMacOS) return "libmonero_wallet2_api_c.dylib";
|
||||
return "/usr/lib/libmonero_wallet2_api_c.so";
|
||||
if (Platform.isWindows)
|
||||
return "monero_libwallet2_api_c.dll";
|
||||
if (Platform.isMacOS) return "monero_libwallet2_api_c.dylib";
|
||||
return "/usr/lib/monero_libwallet2_api_c.so";
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user