near_equal_test.dart 477 Bytes
Newer Older
1
// Copyright 2015 The Chromium Authors. All rights reserved.
Ian Hickson's avatar
Ian Hickson committed
2 3 4 5 6
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

import 'package:test/test.dart';

7
import 'package:flutter/physics.dart';
Ian Hickson's avatar
Ian Hickson committed
8 9 10 11 12 13 14 15 16

void main() {
  test('test_friction', () {
    expect(nearEqual(5.0, 6.0, 2.0), isTrue);
    expect(nearEqual(6.0, 5.0, 2.0), isTrue);
    expect(nearEqual(5.0, 6.0, 0.5), isFalse);
    expect(nearEqual(6.0, 5.0, 0.5), isFalse);
  });
}