Lines Matching full:thread
49 TestHelper::CreateEcmaVMWithScope(instance, thread, scope); in SetUp()
59 JSThread *thread {nullptr}; member in panda::test::BuiltinsObjectTest
62 JSTaggedValue CreateBuiltinJSObject(JSThread *thread, const CString keyCStr) in CreateBuiltinJSObject() argument
64 EcmaVM *ecmaVM = thread->GetEcmaVM(); in CreateBuiltinJSObject()
67 ObjectFactory *factory = thread->GetEcmaVM()->GetFactory(); in CreateBuiltinJSObject()
71 JSHandle<JSTaggedValue> value(thread, JSTaggedValue(1)); in CreateBuiltinJSObject()
72 JSObject::SetProperty(thread, obj, key, value); in CreateBuiltinJSObject()
76 JSFunction *BuiltinsObjectTestCreate(JSThread *thread) in BuiltinsObjectTestCreate() argument
78 EcmaVM *ecmaVM = thread->GetEcmaVM(); in BuiltinsObjectTestCreate()
83 JSObject *TestNewJSObject(JSThread *thread, const JSHandle<JSHClass> &hclass) in TestNewJSObject() argument
85 ObjectFactory *factory = thread->GetEcmaVM()->GetFactory(); in TestNewJSObject()
88 obj->SetElements(thread, factory->EmptyArray().GetTaggedValue(), SKIP_BARRIER); in TestNewJSObject()
95 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
96 JSHandle<JSFunction> objectFunc(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
97 JSHandle<GlobalEnv> globalEnv = thread->GetEcmaVM()->GetGlobalEnv(); in HWTEST_F_L0()
100 auto objCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 4); in HWTEST_F_L0()
104 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, objCallInfo); in HWTEST_F_L0()
106 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
109 …JSHandle<JSObject> jtHandle(thread, JSTaggedValue(reinterpret_cast<TaggedObject *>(result.GetRawDa… in HWTEST_F_L0()
110 …JSTaggedValue resultProto = JSTaggedValue::GetPrototype(thread, JSHandle<JSTaggedValue>(jtHandle)); in HWTEST_F_L0()
117 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>::Cast(function), … in HWTEST_F_L0()
119 auto tgObjCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue(*object), 4); in HWTEST_F_L0()
124 prev = TestHelper::SetupFrame(thread, tgObjCallInfo); in HWTEST_F_L0()
126 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
128 …JSHandle<JSObject> jtHandleTg(thread, JSTaggedValue(reinterpret_cast<TaggedObject *>(resultTg.GetR… in HWTEST_F_L0()
129 …JSTaggedValue resultProtoTg = JSTaggedValue::GetPrototype(thread, JSHandle<JSTaggedValue>(jtHandle… in HWTEST_F_L0()
136 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>::Cast(function), … in HWTEST_F_L0()
138 auto vnObjCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue(*objectVn), 6); in HWTEST_F_L0()
144 prev = TestHelper::SetupFrame(thread, vnObjCallInfo); in HWTEST_F_L0()
146 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
149 …JSHandle<JSObject> jtHandleVn(thread, JSTaggedValue(reinterpret_cast<TaggedObject *>(resultVn.GetR… in HWTEST_F_L0()
150 …JSTaggedValue resultProtoVn = JSTaggedValue::GetPrototype(thread, JSHandle<JSTaggedValue>(jtHandle… in HWTEST_F_L0()
159 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
161 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
163 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
165 JSHandle<JSTaggedValue> key1(thread->GetEcmaVM()->GetFactory()->NewFromASCII("x")); in HWTEST_F_L0()
166 JSHandle<JSTaggedValue> value1(thread, JSTaggedValue(1)); in HWTEST_F_L0()
167 JSObject::SetProperty(thread, JSHandle<JSTaggedValue>(objHandle1), key1, value1); in HWTEST_F_L0()
168 …EXPECT_EQ(JSObject::GetProperty(thread, JSHandle<JSTaggedValue>(objHandle1), key1).GetValue()->Get… in HWTEST_F_L0()
170 JSHandle<JSTaggedValue> key2(thread->GetEcmaVM()->GetFactory()->NewFromASCII("y")); in HWTEST_F_L0()
171 JSHandle<JSTaggedValue> value2(thread, JSTaggedValue(2)); in HWTEST_F_L0()
172 JSObject::SetProperty(thread, JSHandle<JSTaggedValue>(objHandle2), key2, value2); in HWTEST_F_L0()
173 …EXPECT_EQ(JSObject::GetProperty(thread, JSHandle<JSTaggedValue>(objHandle2), key2).GetValue()->Get… in HWTEST_F_L0()
175 …auto assignObjCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(),… in HWTEST_F_L0()
181 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, assignObjCallInfo); in HWTEST_F_L0()
183 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
186 …JSHandle<JSTaggedValue> jtHandle(thread, JSTaggedValue(reinterpret_cast<TaggedObject *>(result.Get… in HWTEST_F_L0()
187 EXPECT_EQ(JSObject::GetProperty(thread, jtHandle, key1).GetValue()->GetInt(), 1); in HWTEST_F_L0()
188 EXPECT_EQ(JSObject::GetProperty(thread, jtHandle, key2).GetValue()->GetInt(), 2); in HWTEST_F_L0()
194 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
195 JSHandle<JSFunction> objectFunc(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
196 JSHandle<JSTaggedValue> funcProto(thread, objectFunc->GetFunctionPrototype()); in HWTEST_F_L0()
199 auto objCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 6); in HWTEST_F_L0()
204 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, objCallInfo); in HWTEST_F_L0()
206 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
209 JSHandle<JSTaggedValue> jtHandle(thread, result); in HWTEST_F_L0()
210 JSTaggedValue resultProto = JSTaggedValue::GetPrototype(thread, jtHandle); in HWTEST_F_L0()
214 JSHandle<JSTaggedValue> key(thread->GetEcmaVM()->GetFactory()->NewFromASCII("prop")); in HWTEST_F_L0()
216 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>::Cast(function), … in HWTEST_F_L0()
219 PropertyDescriptor desc(thread); in HWTEST_F_L0()
221 JSHandle<JSObject> descHandle(JSObject::FromPropertyDescriptor(thread, desc)); in HWTEST_F_L0()
223 PropertyDescriptor descNw(thread, JSHandle<JSTaggedValue>::Cast(descHandle), true, true, true); in HWTEST_F_L0()
224 JSObject::DefineOwnProperty(thread, objHandle, key, descNw); in HWTEST_F_L0()
226 … auto hpObjCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 8); in HWTEST_F_L0()
232 prev = TestHelper::SetupFrame(thread, hpObjCallInfo); in HWTEST_F_L0()
234 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
237 PropertyDescriptor descRes(thread); in HWTEST_F_L0()
238 …bool success = JSObject::GetOwnProperty(thread, JSHandle<JSObject>(thread, resultHp), key, descRes… in HWTEST_F_L0()
243 auto unCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 6); in HWTEST_F_L0()
248 prev = TestHelper::SetupFrame(thread, unCallInfo); in HWTEST_F_L0()
250 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
257 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
258 JSHandle<GlobalEnv> env = thread->GetEcmaVM()->GetGlobalEnv(); in HWTEST_F_L0()
261 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
262 JSHandle<JSTaggedValue> key(thread->GetEcmaVM()->GetFactory()->NewFromASCII("prop")); in HWTEST_F_L0()
264 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
266 PropertyDescriptor desc(thread); in HWTEST_F_L0()
268 JSHandle<JSObject> descHandle(JSObject::FromPropertyDescriptor(thread, desc)); in HWTEST_F_L0()
270 PropertyDescriptor descNw(thread, JSHandle<JSTaggedValue>::Cast(descHandle), true, true, true); in HWTEST_F_L0()
271 JSObject::DefineOwnProperty(thread, jsobjHandle, key, descNw); in HWTEST_F_L0()
273 auto objCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 8); in HWTEST_F_L0()
279 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, objCallInfo); in HWTEST_F_L0()
281 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
285 PropertyDescriptor descRes(thread); in HWTEST_F_L0()
286 JSObject::GetOwnProperty(thread, JSHandle<JSObject>(thread, res), key, descRes); in HWTEST_F_L0()
293 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
295 JSHandle<GlobalEnv> env = thread->GetEcmaVM()->GetGlobalEnv(); in HWTEST_F_L0()
298 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
300 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
302 PropertyDescriptor desc(thread); in HWTEST_F_L0()
304 JSHandle<JSTaggedValue> writableStr = thread->GlobalConstants()->GetHandledWritableString(); in HWTEST_F_L0()
305 JSHandle<JSTaggedValue> writable(thread, JSTaggedValue(desc.IsWritable())); in HWTEST_F_L0()
306 JSObject::CreateDataProperty(thread, attHandle, writableStr, writable); in HWTEST_F_L0()
308 JSHandle<JSTaggedValue> key(thread->GetEcmaVM()->GetFactory()->NewFromASCII("x")); in HWTEST_F_L0()
310 PropertyDescriptor descNw(thread); in HWTEST_F_L0()
311 JSObject::GetOwnProperty(thread, objHandle, key, descNw); in HWTEST_F_L0()
314 … auto objCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 10); in HWTEST_F_L0()
321 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, objCallInfo); in HWTEST_F_L0()
323 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
327 PropertyDescriptor descRes(thread); in HWTEST_F_L0()
328 JSObject::GetOwnProperty(thread, JSHandle<JSObject>(thread, res), key, descRes); in HWTEST_F_L0()
335 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
338 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
340 …auto nofreezeObjCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
345 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, nofreezeObjCallInfo); in HWTEST_F_L0()
352 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
359 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
361 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
363 JSHandle<JSTaggedValue> key(thread->GetEcmaVM()->GetFactory()->NewFromASCII("x")); in HWTEST_F_L0()
365 PropertyDescriptor descEnum(thread); in HWTEST_F_L0()
367 JSTaggedValue::DefinePropertyOrThrow(thread, JSHandle<JSTaggedValue>(objHandle), key, descEnum); in HWTEST_F_L0()
369 auto objCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 8); in HWTEST_F_L0()
375 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, objCallInfo); in HWTEST_F_L0()
377 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
381 JSHandle<JSTaggedValue> writableStr = thread->GlobalConstants()->GetHandledWritableString(); in HWTEST_F_L0()
383 PropertyDescriptor desc(thread); in HWTEST_F_L0()
384 JSObject::GetOwnProperty(thread, JSHandle<JSObject>(thread, jt), writableStr, desc); in HWTEST_F_L0()
391 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
393 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
395 JSHandle<JSTaggedValue> key(thread->GetEcmaVM()->GetFactory()->NewFromASCII("x")); in HWTEST_F_L0()
396 JSHandle<JSTaggedValue> value(thread, JSTaggedValue(1)); in HWTEST_F_L0()
397 JSObject::SetProperty(thread, JSHandle<JSTaggedValue>(objHandle), key, value); in HWTEST_F_L0()
399 auto objCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 6); in HWTEST_F_L0()
404 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, objCallInfo); in HWTEST_F_L0()
406 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
414 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
416 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
417 JSHandle<JSSymbol> symbolKey = thread->GetEcmaVM()->GetFactory()->NewJSSymbol(); in HWTEST_F_L0()
419 JSHandle<JSTaggedValue> value(thread, JSTaggedValue(1)); in HWTEST_F_L0()
420 JSObject::SetProperty(thread, JSHandle<JSTaggedValue>(objHandle), key, value); in HWTEST_F_L0()
421 thread->ClearException(); in HWTEST_F_L0()
423 auto objCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 6); in HWTEST_F_L0()
428 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, objCallInfo); in HWTEST_F_L0()
430 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
439 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
442 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
444 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
446 … auto objCallInfo1 = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 8); in HWTEST_F_L0()
452 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, objCallInfo1); in HWTEST_F_L0()
454 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
463 …JSHandle<EcmaString> testStrValue1 = thread->GetEcmaVM()->GetFactory()->NewFromASCII("helloworld"); in HWTEST_F_L0()
464 …JSHandle<EcmaString> testStrValue2 = thread->GetEcmaVM()->GetFactory()->NewFromASCII("helloworld"); in HWTEST_F_L0()
466 auto strCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 8); in HWTEST_F_L0()
472 prev = TestHelper::SetupFrame(thread, strCallInfo); in HWTEST_F_L0()
474 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
479 … auto boolCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 8); in HWTEST_F_L0()
485 prev = TestHelper::SetupFrame(thread, boolCallInfo); in HWTEST_F_L0()
487 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
492 auto numCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 8); in HWTEST_F_L0()
498 prev = TestHelper::SetupFrame(thread, numCallInfo); in HWTEST_F_L0()
500 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
505 … auto nullCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), 8); in HWTEST_F_L0()
511 prev = TestHelper::SetupFrame(thread, nullCallInfo); in HWTEST_F_L0()
513 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
517 …auto undefineCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), … in HWTEST_F_L0()
523 prev = TestHelper::SetupFrame(thread, undefineCallInfo); in HWTEST_F_L0()
525 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
533 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
537 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
539 …auto emptyObjCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), … in HWTEST_F_L0()
544 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, emptyObjCallInfo); in HWTEST_F_L0()
546 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
558 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
559 JSHandle<JSTaggedValue> key(thread->GetEcmaVM()->GetFactory()->NewFromASCII("x")); in HWTEST_F_L0()
560 JSHandle<JSTaggedValue> value(thread, JSTaggedValue(1)); in HWTEST_F_L0()
564 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>::Cast(function), … in HWTEST_F_L0()
566 …auto emptyObjCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), … in HWTEST_F_L0()
571 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, emptyObjCallInfo); in HWTEST_F_L0()
573 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
578 prev = TestHelper::SetupFrame(thread, emptyObjCallInfo); in HWTEST_F_L0()
580 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
583 PropertyDescriptor descEnum(thread); in HWTEST_F_L0()
587 JSTaggedValue::DefinePropertyOrThrow(thread, JSHandle<JSTaggedValue>(obj), key, descEnum); in HWTEST_F_L0()
589 …auto emptyObjCallInfo2 = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(),… in HWTEST_F_L0()
594 prev = TestHelper::SetupFrame(thread, emptyObjCallInfo2); in HWTEST_F_L0()
596 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
602 JSTaggedValue::DefinePropertyOrThrow(thread, JSHandle<JSTaggedValue>(obj), key, descEnum); in HWTEST_F_L0()
604 …auto emptyObjCallInfo3 = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(),… in HWTEST_F_L0()
609 prev = TestHelper::SetupFrame(thread, emptyObjCallInfo3); in HWTEST_F_L0()
611 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
619 JSHandle<JSTaggedValue> function(thread, BuiltinsObjectTestCreate(thread)); in HWTEST_F_L0()
623 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(function), functi… in HWTEST_F_L0()
625 …auto emptyObjCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(), … in HWTEST_F_L0()
630 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, emptyObjCallInfo); in HWTEST_F_L0()
632 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
640 JSHandle<JSTaggedValue> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
641 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
646 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
648 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
656 JSHandle<JSTaggedValue> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
657 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
662 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
664 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
672 JSHandle<JSObject> obj = JSHandle<JSObject>(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
674 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
679 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
681 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
685 JSHandle<JSObject> jtHandle(thread, jt); in HWTEST_F_L0()
692 JSHandle<JSTaggedValue> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
693 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
698 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
706 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
713 JSHandle<JSObject> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
714 JSHandle<JSObject> objFather(thread, CreateBuiltinJSObject(thread, "y")); in HWTEST_F_L0()
716 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
722 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
724 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
730 JSHandle<JSTaggedValue> key(thread->GetEcmaVM()->GetFactory()->NewFromASCII("y")); in HWTEST_F_L0()
731 …EXPECT_EQ(JSObject::GetProperty(thread, JSHandle<JSTaggedValue>(obj), key).GetValue()->GetInt(), 1… in HWTEST_F_L0()
737 JSHandle<JSTaggedValue> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
739 JSHandle<EcmaString> keyString = thread->GetEcmaVM()->GetFactory()->NewFromASCII(&keyCStr[0]); in HWTEST_F_L0()
742 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
747 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
749 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
757 JSHandle<JSTaggedValue> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
758 JSHandle<JSTaggedValue> objFather(thread, CreateBuiltinJSObject(thread, "y")); in HWTEST_F_L0()
760 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
765 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
767 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
774 JSHandle<JSTaggedValue> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
775 JSHandle<JSTaggedValue> objFather(thread, CreateBuiltinJSObject(thread, "y")); in HWTEST_F_L0()
777 …auto ecmaRuntimeCallInfo1 = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined… in HWTEST_F_L0()
783 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo1); in HWTEST_F_L0()
785 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
790 …auto ecmaRuntimeCallInfo2 = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined… in HWTEST_F_L0()
795 prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo2); in HWTEST_F_L0()
797 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
805 JSHandle<JSTaggedValue> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
806 JSHandle<JSTaggedValue> key(thread->GetEcmaVM()->GetFactory()->NewFromASCII("x")); in HWTEST_F_L0()
808 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
813 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
815 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
823 JSHandle<JSTaggedValue> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
824 JSHandle<JSFunction> calleeFunc = thread->GetEcmaVM()->GetFactory()->NewJSFunction( in HWTEST_F_L0()
825 thread->GetEcmaVM()->GetGlobalEnv(), reinterpret_cast<void *>(BuiltinsObject::ToString)); in HWTEST_F_L0()
828 JSHandle<JSTaggedValue> calleeKey(thread->GetEcmaVM()->GetFactory()->NewFromASCII("toString")); in HWTEST_F_L0()
829 JSObject::SetProperty(thread, obj, calleeKey, calleeValue); in HWTEST_F_L0()
831 …JSHandle<EcmaString> resultValue = thread->GetEcmaVM()->GetFactory()->NewFromASCII("[object Object… in HWTEST_F_L0()
833 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
838 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
840 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
849 … JSHandle<JSTaggedValue> obj = JSHandle<JSTaggedValue>(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
852 …JSHandle<EcmaString> resultValue = thread->GetEcmaVM()->GetFactory()->NewFromASCII("[object Object… in HWTEST_F_L0()
853 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
857 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
859 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
865 JSHandle<JSArray> arr = thread->GetEcmaVM()->GetFactory()->NewJSArray(); in HWTEST_F_L0()
867 thread->GetEcmaVM()->GetFactory()->NewFromASCII("[object Array]"); in HWTEST_F_L0()
868 …auto arrEcmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefin… in HWTEST_F_L0()
872 prev = TestHelper::SetupFrame(thread, arrEcmaRuntimeCallInfo); in HWTEST_F_L0()
874 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
880 JSHandle<EcmaString> str = thread->GetEcmaVM()->GetFactory()->NewFromASCII("hello"); in HWTEST_F_L0()
882 thread->GetEcmaVM()->GetFactory()->NewFromASCII("[object String]"); in HWTEST_F_L0()
883 …auto strEcmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefin… in HWTEST_F_L0()
887 prev = TestHelper::SetupFrame(thread, strEcmaRuntimeCallInfo); in HWTEST_F_L0()
889 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
895 …JSHandle<JSFunction> func = thread->GetEcmaVM()->GetFactory()->NewJSFunction(thread->GetEcmaVM()->… in HWTEST_F_L0()
897 thread->GetEcmaVM()->GetFactory()->NewFromASCII("[object Function]"); in HWTEST_F_L0()
898 …auto funcEcmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefi… in HWTEST_F_L0()
902 prev = TestHelper::SetupFrame(thread, funcEcmaRuntimeCallInfo); in HWTEST_F_L0()
904 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
911 auto ecmaVM = thread->GetEcmaVM(); in HWTEST_F_L0()
915 …thread->GetEcmaVM()->GetFactory()->NewJSObjectByConstructor(JSHandle<JSFunction>(errorObject), err… in HWTEST_F_L0()
916 …JSHandle<EcmaString> errorValue = thread->GetEcmaVM()->GetFactory()->NewFromASCII("[object Error]"… in HWTEST_F_L0()
917 …auto errorEcmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undef… in HWTEST_F_L0()
921 prev = TestHelper::SetupFrame(thread, errorEcmaRuntimeCallInfo); in HWTEST_F_L0()
923 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
929 JSHandle<JSTaggedValue> value(thread, JSTaggedValue::False()); in HWTEST_F_L0()
931 …JSHandle<JSPrimitiveRef> boolean = thread->GetEcmaVM()->GetFactory()->NewJSPrimitiveRef(booleanObj… in HWTEST_F_L0()
933 thread->GetEcmaVM()->GetFactory()->NewFromASCII("[object Boolean]"); in HWTEST_F_L0()
934 …auto boolEcmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefi… in HWTEST_F_L0()
938 prev = TestHelper::SetupFrame(thread, boolEcmaRuntimeCallInfo); in HWTEST_F_L0()
940 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
948 thread->GetEcmaVM()->GetFactory()->NewFromASCII("[object Number]"); in HWTEST_F_L0()
949 …auto numEcmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefin… in HWTEST_F_L0()
953 prev = TestHelper::SetupFrame(thread, numEcmaRuntimeCallInfo); in HWTEST_F_L0()
955 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()
964 JSHandle<JSTaggedValue> obj(thread, CreateBuiltinJSObject(thread, "x")); in HWTEST_F_L0()
965 …auto ecmaRuntimeCallInfo = TestHelper::CreateEcmaRuntimeCallInfo(thread, JSTaggedValue::Undefined(… in HWTEST_F_L0()
970 [[maybe_unused]] auto prev = TestHelper::SetupFrame(thread, ecmaRuntimeCallInfo); in HWTEST_F_L0()
972 TestHelper::TearDownFrame(thread, prev); in HWTEST_F_L0()