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

Unified Diff: runtime/observatory/tests/service/set_library_debuggable_rpc_test.dart

Issue 2759973004: Fix observatory tests broken by running dartfmt. Temporarily reverted formatting for evaluate_activ… (Closed)
Patch Set: Created 3 years, 9 months 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: runtime/observatory/tests/service/set_library_debuggable_rpc_test.dart
diff --git a/runtime/observatory/tests/service/set_library_debuggable_rpc_test.dart b/runtime/observatory/tests/service/set_library_debuggable_rpc_test.dart
index 0571376dc24bb1a97bb66af75c25a7f8b2a3efd7..9877f636e299d29bdfb0d40c3dd6d4b1d4c7bd51 100644
--- a/runtime/observatory/tests/service/set_library_debuggable_rpc_test.dart
+++ b/runtime/observatory/tests/service/set_library_debuggable_rpc_test.dart
@@ -18,8 +18,7 @@ var tests = [
var getObjectParams = {
'objectId': isolate.rootLibrary.id,
};
- result = await isolate.invokeRpcNoUpgrade('getObject',
- getObjectParams);
+ result = await isolate.invokeRpcNoUpgrade('getObject', getObjectParams);
expect(result['debuggable'], equals(true));
// Change debuggable to false.
@@ -27,15 +26,13 @@ var tests = [
'libraryId': isolate.rootLibrary.id,
'isDebuggable': false,
};
- result = await isolate.invokeRpcNoUpgrade('setLibraryDebuggable',
- setDebugParams);
+ result = await isolate.invokeRpcNoUpgrade(
+ 'setLibraryDebuggable', setDebugParams);
expect(result['type'], equals('Success'));
// Verify.
- result = await isolate.invokeRpcNoUpgrade('getObject',
- getObjectParams);
+ result = await isolate.invokeRpcNoUpgrade('getObject', getObjectParams);
expect(result['debuggable'], equals(false));
-
},
// invalid library.
@@ -47,13 +44,14 @@ var tests = [
bool caughtException;
try {
await isolate.invokeRpcNoUpgrade('setLibraryDebuggable', params);
- expect(false, isTrue, reason:'Unreachable');
- } on ServerRpcException catch(e) {
+ expect(false, isTrue, reason: 'Unreachable');
+ } on ServerRpcException catch (e) {
caughtException = true;
expect(e.code, equals(ServerRpcException.kInvalidParams));
- expect(e.message,
- "setLibraryDebuggable: "
- "invalid 'libraryId' parameter: libraries/9999999");
+ expect(
+ e.message,
+ "setLibraryDebuggable: "
+ "invalid 'libraryId' parameter: libraries/9999999");
}
expect(caughtException, isTrue);
},
@@ -61,8 +59,8 @@ var tests = [
// illegal (dart:_*) library.
(Isolate isolate) async {
await isolate.load();
- Library dartInternal = isolate.libraries.firstWhere(
- (Library library) => library.uri == 'dart:_internal');
+ Library dartInternal = isolate.libraries
+ .firstWhere((Library library) => library.uri == 'dart:_internal');
var params = {
'libraryId': dartInternal.id,
'isDebuggable': false,
@@ -70,13 +68,14 @@ var tests = [
bool caughtException;
try {
await isolate.invokeRpcNoUpgrade('setLibraryDebuggable', params);
- expect(false, isTrue, reason:'Unreachable');
- } on ServerRpcException catch(e) {
+ expect(false, isTrue, reason: 'Unreachable');
+ } on ServerRpcException catch (e) {
caughtException = true;
expect(e.code, equals(ServerRpcException.kInvalidParams));
- expect(e.message,
- "setLibraryDebuggable: "
- "illegal 'libraryId' parameter: ${dartInternal.id}");
+ expect(
+ e.message,
+ "setLibraryDebuggable: "
+ "illegal 'libraryId' parameter: ${dartInternal.id}");
}
expect(caughtException, isTrue);
},

Powered by Google App Engine
This is Rietveld 408576698