aboutsummaryrefslogtreecommitdiffstats
path: root/external/contributions/Google/sputniktests/tests/Implementation_Diagnostics/S15.1.2.2_D1.1.js
blob: da793b1a8f648218a7e74dd38be2cb30d54a6214 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
// Copyright 2009 the Sputnik authors.  All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.

/**
 * @name: S15.1.2.2_D1.1;
 * @section: 15.1.2.2, 9.8;
 * @assertion: If the length of S is at least 1 and the first character of S is 0, 
 * then R = 8;
*/

//CHECK#2
if (parseInt("08") !== parseInt("08", 8)) {
  $ERROR('#1: parseInt("08") === parseInt("08", 8)');
}

//CHECK#2
if (parseInt("09") !== parseInt("09", 8)) {
  $ERROR('#2: parseInt("09") === parseInt("09", 8)');
}

//CHECK#3
if (parseInt("010") !== parseInt("010", 8)) {
  $ERROR('#3: parseInt("010") === parseInt("010", 8)');
}