libdart_openmvg/tests/main_test.dart

28 lines
758 B
Dart
Raw Normal View History

2024-03-11 18:42:48 +01:00
import 'dart:ffi';
import 'dart:io';
import 'package:archimedes_mobile_lib/archimedes_c_shim.dart';
import 'package:archimedes_mobile_lib/dynloader.dart';
import 'package:archimedes_mobile_lib/util.dart';
import 'package:ffi/ffi.dart';
import 'package:test/test.dart';
import "package:path/path.dart" show dirname, join;
final assets = join(HERE.parent.path, "assets");
final testFrames = join(assets, "test", "frames");
final firstFrame = join(testFrames, "0001.png");
void main() {
group('Unit Tests', () {
setUp(() {});
tearDown(() {
// Tear down code
});
test('newFrame', () {
2024-03-12 02:09:11 +01:00
Uint8FlexList frameData = readUint8Ptr(File(firstFrame));
newFrame(frameData.pointer, frameData.length, 768, 768, 1204);
2024-03-11 18:42:48 +01:00
});
});
}