Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(764)

Unified Diff: services/dart/dart_apptests/lib/src/io_internet_address_apptests.dart

Issue 1545483003: Dart: Reorganize files (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Fix build file Created 5 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: services/dart/dart_apptests/lib/src/io_internet_address_apptests.dart
diff --git a/services/dart/dart_apptests/lib/src/io_internet_address_apptests.dart b/services/dart/dart_apptests/lib/src/io_internet_address_apptests.dart
deleted file mode 100644
index 80c38e61c418c147b8652dea5cbc9525b562dbbd..0000000000000000000000000000000000000000
--- a/services/dart/dart_apptests/lib/src/io_internet_address_apptests.dart
+++ /dev/null
@@ -1,67 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-library io_internet_address_apptests;
-
-import 'dart:async';
-import 'dart:io';
-
-import 'package:mojo_apptest/apptest.dart';
-import 'package:mojo/application.dart';
-import 'package:mojo/bindings.dart';
-import 'package:mojo/core.dart';
-
-tests(Application application, String url) {
- group('InternetAddress Apptests', () {
- test('Parse IPv4', () async {
- var localhost = new InternetAddress('127.0.0.1');
- expect(localhost, equals(InternetAddress.LOOPBACK_IP_V4));
- });
- test('Parse IPv6', () async {
- var localhost = new InternetAddress('0:0:0:0:0:0:0:1');
- expect(localhost, equals(InternetAddress.LOOPBACK_IP_V6));
- });
- test('Reverse', () async {
- var result = await InternetAddress.LOOPBACK_IP_V4.reverse();
- expect(result.host, equals('localhost'));
- });
- test('Lookup IPv4', () async {
- var result =
- await InternetAddress.lookup('localhost',
- type:InternetAddressType.IP_V4);
- expect(result.length, greaterThan(0));
- expect(result[0], equals(InternetAddress.LOOPBACK_IP_V4));
- });
- test('Lookup IPv6', () async {
- try {
- var result =
- await InternetAddress.lookup('localhost',
- type:InternetAddressType.IP_V6);
- expect(result.length, greaterThan(0));
- expect(result[0], equals(InternetAddress.LOOPBACK_IP_V6));
- } on OSError catch (e) {
- expect(e.message, stringContainsInOrder(["ERR_NAME_NOT_RESOLVED"]));
- }
- });
- test('Lookup ANY', () async {
- var result =
- await InternetAddress.lookup('localhost',
- type:InternetAddressType.ANY);
- expect(result.length, greaterThan(0));
- });
- test('Lookup failure', () async {
- var result;
- var exceptionCaught = false;
- try {
- result = await InternetAddress.lookup('local.7778888');
- // Not hit.
- expect(true, isFalse);
- } on OSError catch(e) {
- exceptionCaught = true;
- expect(e.errorCode, isNot(equals(0)));
- }
- expect(exceptionCaught, isTrue);
- });
- });
-}
« no previous file with comments | « services/dart/dart_apptests/lib/src/io_http_apptests.dart ('k') | services/dart/dart_apptests/lib/src/pingpong_apptests.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698