Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion testing/dart/encoding_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ class GrayscaleImage {
GrayscaleImage._();

static Future<Image> load() async {
final Uint8List bytes = await readFile('4x4.png');
final Uint8List bytes = await readFile('2x2.png');
final Completer<Image> completer = Completer<Image>();
decodeImageFromList(bytes, (Image image) => completer.complete(image));
return await completer.future;
Expand Down
2 changes: 1 addition & 1 deletion testing/dart/image_descriptor_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import 'package:test/test.dart';

void main() {
test('basic image descriptor - encoded - greyscale', () async {
final Uint8List bytes = await readFile('4x4.png');
final Uint8List bytes = await readFile('2x2.png');
final ImmutableBuffer buffer = await ImmutableBuffer.fromUint8List(bytes);
final ImageDescriptor descriptor = await ImageDescriptor.encoded(buffer);

Expand Down
14 changes: 7 additions & 7 deletions testing/dart/image_resize_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ void main() {
}());

test('no resize by default', () async {
final Uint8List bytes = await readFile('4x4.png');
final Uint8List bytes = await readFile('2x2.png');
final Codec codec = await instantiateImageCodec(bytes);
final FrameInfo frame = await codec.getNextFrame();
final int codecHeight = frame.image.height;
Expand All @@ -29,7 +29,7 @@ void main() {
});

test('resize width with constrained height', () async {
final Uint8List bytes = await readFile('4x4.png');
final Uint8List bytes = await readFile('2x2.png');
final Codec codec = await instantiateImageCodec(bytes, targetHeight: 1);
final FrameInfo frame = await codec.getNextFrame();
final int codecHeight = frame.image.height;
Expand All @@ -39,7 +39,7 @@ void main() {
});

test('resize height with constrained width', () async {
final Uint8List bytes = await readFile('4x4.png');
final Uint8List bytes = await readFile('2x2.png');
final Codec codec = await instantiateImageCodec(bytes, targetWidth: 1);
final FrameInfo frame = await codec.getNextFrame();
final int codecHeight = frame.image.height;
Expand All @@ -49,7 +49,7 @@ void main() {
});

test('upscale image by 5x', () async {
final Uint8List bytes = await readFile('4x4.png');
final Uint8List bytes = await readFile('2x2.png');
final Codec codec = await instantiateImageCodec(bytes, targetWidth: 10, allowUpscaling: true);
final FrameInfo frame = await codec.getNextFrame();
final int codecHeight = frame.image.height;
Expand All @@ -59,7 +59,7 @@ void main() {
});

test('upscale image by 5x - no upscaling', () async {
final Uint8List bytes = await readFile('4x4.png');
final Uint8List bytes = await readFile('2x2.png');
final Codec codec = await instantiateImageCodec(bytes, targetWidth: 10, allowUpscaling: false);
final FrameInfo frame = await codec.getNextFrame();
final int codecHeight = frame.image.height;
Expand All @@ -69,7 +69,7 @@ void main() {
});

test('upscale image varying width and height', () async {
final Uint8List bytes = await readFile('4x4.png');
final Uint8List bytes = await readFile('2x2.png');
final Codec codec =
await instantiateImageCodec(bytes, targetWidth: 10, targetHeight: 1, allowUpscaling: true);
final FrameInfo frame = await codec.getNextFrame();
Expand All @@ -80,7 +80,7 @@ void main() {
});

test('upscale image varying width and height - no upscaling', () async {
final Uint8List bytes = await readFile('4x4.png');
final Uint8List bytes = await readFile('2x2.png');
final Codec codec =
await instantiateImageCodec(bytes, targetWidth: 10, targetHeight: 1, allowUpscaling: false);
final FrameInfo frame = await codec.getNextFrame();
Expand Down
File renamed without changes