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

Unified Diff: third_party/pkg/angular/lib/mock/log.dart

Issue 1058283006: Update pubspecs and dependencies to get pkgbuild tests working. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 8 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: third_party/pkg/angular/lib/mock/log.dart
diff --git a/third_party/pkg/angular/lib/mock/log.dart b/third_party/pkg/angular/lib/mock/log.dart
deleted file mode 100644
index ca8c745dbdc4b6496db7060f8a261ac301683744..0000000000000000000000000000000000000000
--- a/third_party/pkg/angular/lib/mock/log.dart
+++ /dev/null
@@ -1,66 +0,0 @@
-part of angular.mock;
-
-/**
- * A convenient way to assert the order in which the DOM elements are processed.
- *
- * In your test create:
- *
- * <div log="foo">...</div>
- *
- * And then assert:
- *
- * expect(logger).toEqual(['foo']);
- */
-@NgDirective(
- selector: '[log]',
- map: const {
- 'log': '@logMessage'
- })
-class LogAttrDirective implements NgAttachAware {
- final Logger log;
- String logMessage;
- LogAttrDirective(this.log);
- void attach() {
- log(logMessage == '' ? 'LOG' : logMessage);
- }
-}
-
-/**
- * A convenient way to verify that a set of operations executed in a specific
- * order. Simply inject the Logger into each operation and call:
- *
- * operation1(Logger logger) => logger('foo');
- * operation2(Logger logger) => logger('bar');
- *
- * Then in the test:
- *
- * expect(logger).toEqual(['foo', 'bar']);
- */
-class Logger extends ListBase {
- final tokens = [];
-
- /**
- * Add string token to the list.
- */
- void call(text) {
- tokens.add(text);
- }
-
- /**
- * Return a `;` separated list of recorded tokens.
- */
- String result() => tokens.join('; ');
-
-
- int get length => tokens.length;
-
- operator [](int index) => tokens[index];
-
- void operator []=(int index, value) {
- tokens[index] = value;
- }
-
- void set length(int newLength) {
- tokens.length = newLength;
- }
-}
« no previous file with comments | « third_party/pkg/angular/lib/mock/http_backend.dart ('k') | third_party/pkg/angular/lib/mock/mock_window.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698