You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@thrift.apache.org by me...@apache.org on 2016/03/01 23:59:36 UTC

thrift git commit: THRIFT-3702 Fix cross tests for Dart compact protocol (3 failing) Client: Dart Patch: Mark Erickson

Repository: thrift
Updated Branches:
  refs/heads/master b5f126f6d -> 56c1c645f


THRIFT-3702 Fix cross tests for Dart compact protocol (3 failing)
Client: Dart
Patch: Mark Erickson

This closes #917


Project: http://git-wip-us.apache.org/repos/asf/thrift/repo
Commit: http://git-wip-us.apache.org/repos/asf/thrift/commit/56c1c645
Tree: http://git-wip-us.apache.org/repos/asf/thrift/tree/56c1c645
Diff: http://git-wip-us.apache.org/repos/asf/thrift/diff/56c1c645

Branch: refs/heads/master
Commit: 56c1c645f299c6570ad4c8469dbeb87fa22d8f11
Parents: b5f126f
Author: Mark Erickson <me...@apache.org>
Authored: Tue Mar 1 16:53:35 2016 -0600
Committer: Mark Erickson <me...@apache.org>
Committed: Tue Mar 1 16:53:35 2016 -0600

----------------------------------------------------------------------
 test/dart/test_client/bin/main.dart | 12 +++++++-----
 test/dart/test_client/pubspec.yaml  |  1 +
 test/known_failures_Linux.json      |  5 ++++-
 3 files changed, 12 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/thrift/blob/56c1c645/test/dart/test_client/bin/main.dart
----------------------------------------------------------------------
diff --git a/test/dart/test_client/bin/main.dart b/test/dart/test_client/bin/main.dart
index 2f5bb70..78a4f79 100644
--- a/test/dart/test_client/bin/main.dart
+++ b/test/dart/test_client/bin/main.dart
@@ -20,7 +20,8 @@ import 'dart:convert';
 import 'dart:io';
 
 import 'package:args/args.dart';
-import 'package:collection/equality.dart';
+import 'package:collection/collection.dart';
+import 'package:http/http.dart' as http;
 import 'package:thrift/thrift.dart';
 import 'package:thrift/thrift_console.dart';
 import 'package:thrift_test/thrift_test.dart';
@@ -151,8 +152,9 @@ Future _initTestClient(
   var protocolFactory = getProtocolFactory(protocolType);
 
   if (transportType == 'http') {
-    var httpClient = new HttpClient();
-    var config = new THttpConfig(Uri.parse('http://localhost'), {});
+    var httpClient = new http.IOClient();
+    var uri = Uri.parse('http://$host:$port');
+    var config = new THttpConfig(uri, {});
     transport = new THttpClientTransport(httpClient, config);
   } else {
     var socket = await Socket.connect(host, port);
@@ -309,7 +311,7 @@ List<TTest> _createTests() {
   tests.add(new TTest(TEST_EXCEPTIONS, 'testException', () async {
     try {
       await client.testException('Xception');
-    } on Xception catch (x) {
+    } on Xception catch (_) {
       return;
     }
 
@@ -319,7 +321,7 @@ List<TTest> _createTests() {
   tests.add(new TTest(TEST_EXCEPTIONS, 'testMultiException', () async {
     try {
       await client.testMultiException('Xception2', 'foo');
-    } on Xception2 catch (x) {
+    } on Xception2 catch (_) {
       return;
     }
 

http://git-wip-us.apache.org/repos/asf/thrift/blob/56c1c645/test/dart/test_client/pubspec.yaml
----------------------------------------------------------------------
diff --git a/test/dart/test_client/pubspec.yaml b/test/dart/test_client/pubspec.yaml
index b76fb5d..493ee32 100644
--- a/test/dart/test_client/pubspec.yaml
+++ b/test/dart/test_client/pubspec.yaml
@@ -24,6 +24,7 @@ environment:
   sdk: ^1.12.0
 dependencies:
   args: ^0.13.0
+  http: ^0.11.0
   thrift:
     path: ../../../lib/dart
   thrift_test:

http://git-wip-us.apache.org/repos/asf/thrift/blob/56c1c645/test/known_failures_Linux.json
----------------------------------------------------------------------
diff --git a/test/known_failures_Linux.json b/test/known_failures_Linux.json
index a27b27a..7b51d1f 100644
--- a/test/known_failures_Linux.json
+++ b/test/known_failures_Linux.json
@@ -19,6 +19,7 @@
   "cpp-cpp_json_http-ip",
   "cpp-cpp_json_http-ip-ssl",
   "cpp-dart_binary_http-ip",
+  "cpp-dart_compact_http-ip",
   "cpp-dart_json_http-ip",
   "cpp-go_binary_http-ip",
   "cpp-go_binary_http-ip-ssl",
@@ -101,8 +102,8 @@
   "go-cpp_json_http-ip-ssl",
   "go-dart_binary_framed-ip",
   "go-dart_binary_http-ip",
+  "go-dart_compact_http-ip",
   "go-dart_json_framed-ip",
-  "go-nodejs_json_framed-ip",
   "go-dart_json_http-ip",
   "go-java_binary_http-ip",
   "go-java_binary_http-ip-ssl",
@@ -110,12 +111,14 @@
   "go-java_compact_http-ip-ssl",
   "go-java_json_http-ip",
   "go-java_json_http-ip-ssl",
+  "go-nodejs_json_framed-ip",
   "go-perl_binary_buffered-ip-ssl",
   "go-perl_binary_framed-ip-ssl",
   "hs-csharp_binary_framed-ip",
   "hs-csharp_compact_framed-ip",
   "hs-csharp_json_framed-ip",
   "hs-dart_binary_framed-ip",
+  "hs-dart_compact_framed-ip",
   "hs-dart_json_framed-ip",
   "hs-py3_json_buffered-ip",
   "hs-py3_json_framed-ip",