OLD | NEW |
---|---|
(Empty) | |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | |
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. | |
4 // Test num.clamp. | |
Bob Nystrom
2017/07/31 21:26:40
You can just delete this test. We no longer need t
| |
5 | |
6 import "package:expect/expect.dart"; | |
7 | |
8 testIntClamp() { | |
9 var a = 0.clamp("str", -1); /*@compile-error=unspecified*/ | |
10 var b = 0.clamp(0, "2"); /*@compile-error=unspecified*/ | |
11 } | |
12 | |
13 testDoubleClamp() { | |
14 var a = 0.0.clamp("str", -1.0); /*@compile-error=unspecified*/ | |
15 var b = 0.0.clamp(0.0, "2"); /*@compile-error=unspecified*/ | |
16 } | |
17 | |
18 testDoubleClampInt() { | |
19 var a = 0.0.clamp("str", -1); /*@compile-error=unspecified*/ | |
20 var b = 0.0.clamp(0, "2"); /*@compile-error=unspecified*/ | |
21 } | |
22 | |
23 main() { | |
24 testIntClamp(); | |
25 testDoubleClamp(); | |
26 testDoubleClampInt(); | |
27 } | |
OLD | NEW |