| OLD | NEW |
| 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 library test.src.task.model_test; | 5 library test.src.task.model_test; |
| 6 | 6 |
| 7 import 'package:analyzer/src/generated/engine.dart' hide AnalysisTask; | 7 import 'package:analyzer/src/generated/engine.dart' hide AnalysisTask; |
| 8 import 'package:analyzer/src/generated/java_engine.dart'; | 8 import 'package:analyzer/src/generated/java_engine.dart'; |
| 9 import 'package:analyzer/src/task/model.dart'; | 9 import 'package:analyzer/src/task/model.dart'; |
| 10 import 'package:analyzer/task/model.dart'; | 10 import 'package:analyzer/task/model.dart'; |
| (...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 100 expect(contributors, unorderedEquals([result])); | 100 expect(contributors, unorderedEquals([result])); |
| 101 } | 101 } |
| 102 | 102 |
| 103 test_create_withoutContribution() { | 103 test_create_withoutContribution() { |
| 104 expect(new ResultDescriptorImpl('name', null), isNotNull); | 104 expect(new ResultDescriptorImpl('name', null), isNotNull); |
| 105 } | 105 } |
| 106 | 106 |
| 107 test_inputFor() { | 107 test_inputFor() { |
| 108 AnalysisTarget target = new TestSource(); | 108 AnalysisTarget target = new TestSource(); |
| 109 ResultDescriptorImpl result = new ResultDescriptorImpl('result', null); | 109 ResultDescriptorImpl result = new ResultDescriptorImpl('result', null); |
| 110 TaskInput input = result.inputFor(target); | 110 TaskInput input = result.of(target); |
| 111 expect(input, isNotNull); | 111 expect(input, isNotNull); |
| 112 } | 112 } |
| 113 | 113 |
| 114 test_name() { | 114 test_name() { |
| 115 String name = 'result'; | 115 String name = 'result'; |
| 116 ResultDescriptorImpl result = new ResultDescriptorImpl(name, null); | 116 ResultDescriptorImpl result = new ResultDescriptorImpl(name, null); |
| 117 expect(result.name, name); | 117 expect(result.name, name); |
| 118 } | 118 } |
| 119 } | 119 } |
| 120 | 120 |
| (...skipping 23 matching lines...) Expand all Loading... |
| 144 AnalysisContext context = null; | 144 AnalysisContext context = null; |
| 145 AnalysisTarget target = new TestSource(); | 145 AnalysisTarget target = new TestSource(); |
| 146 Map<String, dynamic> inputs = {}; | 146 Map<String, dynamic> inputs = {}; |
| 147 AnalysisTask createTask = descriptor.createTask(context, target, inputs); | 147 AnalysisTask createTask = descriptor.createTask(context, target, inputs); |
| 148 expect(createTask, isNotNull); | 148 expect(createTask, isNotNull); |
| 149 expect(createTask.context, context); | 149 expect(createTask.context, context); |
| 150 expect(createTask.inputs, inputs); | 150 expect(createTask.inputs, inputs); |
| 151 expect(createTask.target, target); | 151 expect(createTask.target, target); |
| 152 } | 152 } |
| 153 } | 153 } |
| OLD | NEW |