Debian Codegraph @

tests/auto/qml/ecmascripttests/test262/test/built-ins/Object/assign/OnlyOneArgument.js

raw
1 // Copyright 2015 Microsoft Corporation. All rights reserved.
2 // This code is governed by the license found in the LICENSE file.
3
4 /*---
5 description: >
6 test Object.Assign(target,...sources),only one argument was passed,
7 return ToObject(target)
8 es6id: 19.1.2.1.3
9 ---*/
10
11 var target = "a";
12 var result = Object.assign(target);
13
14 assert.sameValue(typeof result, "object");
15 assert.sameValue(result.valueOf(), "a", "The value should be 'a'.");