dart-sdk/tests/ffi/vmspecific_deprecated_funcs_test.dart
Daco Harkes fbee607329 [vm/ffi] Cleanup tests
Address all warnings and errors in positive tests.

Move all static checks tests to tests/ffi/static_checks/ so it's
easier to ignore them in the analyzer.

Change-Id: I16ac2c00432a4e1b6750bffd9b03ac8a2e988fe6
Cq-Include-Trybots: luci.dart.try:vm-fuchsia-release-arm64-try,vm-fuchsia-release-x64-try
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/351123
Reviewed-by: Liam Appelbe <liama@google.com>
2024-02-09 21:27:29 +00:00

23 lines
727 B
Dart

// Copyright (c) 2023, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
//
// SharedObjects=ffi_test_functions
import 'dart:ffi';
import 'dylib_utils.dart';
final ffiTestFunctions = dlopenPlatformSpecific("ffi_test_functions");
final initializeApi = ffiTestFunctions.lookupFunction<
IntPtr Function(Pointer<Void>),
int Function(Pointer<Void>)>("InitDartApiDL");
main() {
initializeApi(NativeApi.initializeApiDLData);
final isDeprecated =
ffiTestFunctions.lookupFunction<Void Function(), void Function()>(
"TestDeprecatedSymbols");
isDeprecated();
}