File tree Expand file tree Collapse file tree 3 files changed +25
-1
lines changed Expand file tree Collapse file tree 3 files changed +25
-1
lines changed Original file line number Diff line number Diff line change
1
+ ObjectCopy succeeded
2
+ ObjectCopy: Can't copy: Don't have PathTypeHandler
3
+ ObjectCopy: Can't copy: type handler has accessors
4
+ ObjectCopy: Can't copy: type handler has accessors
5
+ ObjectCopy: Can't copy: Protoytypes don't match
6
+ ObjectCopy: Can't copy: from obj has non-enumerable properties
7
+ ObjectCopy succeeded
8
+ pass
Original file line number Diff line number Diff line change @@ -87,6 +87,21 @@ var tests = [
87
87
assert . areEqual ( newObj . b , undefined ) ;
88
88
assert . areEqual ( newObj . a , orig . a ) ;
89
89
}
90
+ } ,
91
+ {
92
+ name : "proto accessor" ,
93
+ body : function ( )
94
+ {
95
+ Object . defineProperty ( Object . prototype , 'b' , {
96
+ get : function ( ) { return "asdf" ; }
97
+ } ) ;
98
+ let orig = { } ;
99
+ orig . a = 1 ;
100
+
101
+ let newObj = Object . assign ( { } , orig ) ;
102
+ assert . areEqual ( newObj . b , "asdf" ) ;
103
+ assert . areEqual ( newObj . a , orig . a ) ;
104
+ }
90
105
}
91
106
] ;
92
107
Original file line number Diff line number Diff line change 439
439
<test >
440
440
<default >
441
441
<files >assign.js</files >
442
- <compile-flags >-args summary -endargs</compile-flags >
442
+ <compile-flags >-args summary -endargs -trace:ObjectCopy</compile-flags >
443
+ <baseline >assign.baseline</baseline >
443
444
</default >
444
445
</test >
445
446
</regress-exe >
You can’t perform that action at this time.
0 commit comments