Jens Geyer created THRIFT-6172:
----------------------------------
Summary: Dart tests are not run by make check, and no CI job
builds the binding
Key: THRIFT-6172
URL: https://issues.apache.org/jira/browse/THRIFT-6172
Project: Thrift
Issue Type: New Feature
Components: Build Process, Dart - Library
Reporter: Jens Geyer
No CI job builds or tests the Dart binding, and `make check` does not run its
tests either. The second half is the part that has to be fixed first.
.github/workflows/build.yml has jobs for php, go, java-kotlin, netstd, haxe,
rust, python, nodejs, cpp and ruby, but none for Dart, and both build.yml and
sca.yml pass --without-dart in their shared CONFIG_ARGS_FOR_LIBS.
Two prerequisites, both concrete and both checkable today:
1. `make check` runs no Dart tests. lib/dart/Makefile.am has "check-local:
all", and "all-local" is "dart pub get". There are eight test files under
lib/dart/test (transport, protocol, serializer, t_application_error), and
nothing in the build system ever invokes "dart test" on them. A CI job wired to
"make -C lib/dart check" today would resolve dependencies and report success
without executing a single test.
2. The Dart SDK pinned in the docker images is older than the library's own
minimum. build/docker/ubuntu-{focal,jammy,noble}/Dockerfile set
DART_VERSION=2.7.2-1, while lib/dart/pubspec.yaml requires environment sdk
">=2.12.0 <4.0.0". "dart pub get" cannot satisfy that constraint in the
project's own images. LANGUAGES.md also records the tested Dart language levels
as 2.0.0 to 2.4.0, which matches the image pin and not the pubspec. See
THRIFT-5712 (Add Dart 3 compatibility) and THRIFT-5372.
So this is not the same shape as THRIFT-6170 (D) or the Erlang equivalent,
where the toolchain is provisioned and the test entry point already works. Here
the ordering is: raise the SDK pin, make check-local actually run "dart test",
then add the job. The first two are worth doing on their own merits even if the
CI job never follows, because until they are done the eight test files in the
tree are decorative.
Compare THRIFT-6002 (netstd), THRIFT-6003 (haxe) and THRIFT-6170 (D).
--
This message was sent by Atlassian Jira
(v8.20.10#820010)