aboutsummaryrefslogtreecommitdiff
path: root/contexts/data/lib/closure-library/closure/goog/labs/testing/numbermatcher_test.html
diff options
context:
space:
mode:
Diffstat (limited to 'contexts/data/lib/closure-library/closure/goog/labs/testing/numbermatcher_test.html')
-rw-r--r--contexts/data/lib/closure-library/closure/goog/labs/testing/numbermatcher_test.html79
1 files changed, 0 insertions, 79 deletions
diff --git a/contexts/data/lib/closure-library/closure/goog/labs/testing/numbermatcher_test.html b/contexts/data/lib/closure-library/closure/goog/labs/testing/numbermatcher_test.html
deleted file mode 100644
index 3d1f40f..0000000
--- a/contexts/data/lib/closure-library/closure/goog/labs/testing/numbermatcher_test.html
+++ /dev/null
@@ -1,79 +0,0 @@
-<!DOCTYPE html>
-<html>
-<!--
-Copyright 2012 The Closure Library Authors. All Rights Reserved.
-
-Use of this source code is governed by the Apache License, Version 2.0.
-See the COPYING file for details.
--->
-<head>
-<title>Closure Unit Tests - Number matchers</title>
-<script src="../../base.js"></script>
-<script>
-
-goog.require('goog.labs.testing.CloseToMatcher');
-goog.require('goog.labs.testing.EqualToMatcher');
-goog.require('goog.labs.testing.GreaterThanEqualToMatcher');
-goog.require('goog.labs.testing.GreaterThanMatcher');
-goog.require('goog.labs.testing.LessThanEqualToMatcher');
-goog.require('goog.labs.testing.LessThanMatcher');
-goog.require('goog.labs.testing.assertThat');
-goog.require('goog.testing.jsunit');
-
-</script>
-</head>
-<body>
-<script>
-
-function testGreaterThan() {
- goog.labs.testing.assertThat(4, greaterThan(3), '4 > 3');
- assertMatcherError(function() {
- goog.labs.testing.assertThat(2, greaterThan(3));
- }, '2 > 3');
-}
-
-function testGreaterThanEqualTo() {
- goog.labs.testing.assertThat(5, greaterThanEqualTo(4), '5 >= 4');
- goog.labs.testing.assertThat(5, greaterThanEqualTo(5), '5 >= 5');
- assertMatcherError(function() {
- goog.labs.testing.assertThat(3, greaterThanEqualTo(5));
- }, '3 >= 5');
-}
-
-function testLessThan() {
- goog.labs.testing.assertThat(6, lessThan(7), '6 < 7');
- assertMatcherError(function() {
- goog.labs.testing.assertThat(7, lessThan(5));
- }, '7 < 5');
-}
-
-function testLessThanEqualTo() {
- goog.labs.testing.assertThat(8, lessThanEqualTo(8), '8 <= 8');
- goog.labs.testing.assertThat(8, lessThanEqualTo(9), '8 <= 9');
- assertMatcherError(function() {
- goog.labs.testing.assertThat(7, lessThanEqualTo(5));
- }, '7 <= 5');
-}
-
-function testEqualTo() {
- goog.labs.testing.assertThat(7, equalTo(7), '7 equals 7');
- assertMatcherError(function() {
- goog.labs.testing.assertThat(7, equalTo(5));
- }, '7 == 5');
-}
-
-function testCloseTo() {
- goog.labs.testing.assertThat(7, closeTo(10, 4), '7 within range(4) of 10');
- assertMatcherError(function() {
- goog.labs.testing.assertThat(5, closeTo(10, 3));
- }, '5 within range(3) of 10');
-}
-
-function assertMatcherError(callable, errorString) {
- var e = assertThrows(errorString || 'callable throws exception', callable);
- assertTrue(e instanceof goog.labs.testing.MatcherError);
-}
-
-</script>
-</body>
-</html>