blob: 61ee6f31490df0907edf83c953ab63a6a53ce45c (
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
25
26
27
28
29
30
31
32
33
34
35
36
37
|
// Copyright 2009 the Sputnik authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/**
* @name: S10.1.3_A3;
* @section: 10.1.3;
* @assertion: If the value of this last parameter (which has the same
* name as some previous parameters do) was not supplied by the
* caller, the value of the corresponding property is undefined;
* @description: Creating functions with two or more formal parameters,
* that have the same name. Calling this function excluding a few last parameters;
*/
// Converted for Test262 from original Sputnik source
ES5Harness.registerTest( {
id: "S10.1.3_A3",
path: "TestCases/10_Execution_Contexts/10.1_Definitions/10.1.3_Variable_Instantiation/S10.1.3_A3.js",
assertion: "If the value of this last parameter (which has the same",
description: "Creating functions with two or more formal parameters,",
test: function testcase() {
//CHECK#1
function f1(x, a, b, x){
return x;
}
if(!(f1(1, 2) === undefined)){
$ERROR('#1: f1(1, 2) === undefined');
}
}
});
|