You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
it('only checks own properties for `slots` validation',async()=>{
151
+
// Temporarily pollute Object.prototype to simulate inherited properties
152
+
Object.prototype.slots={default: 'polluted'};
153
+
try{
154
+
constreq=makePostRequest({
155
+
encryptedComponentExport: 'encExport',
156
+
encryptedProps: 'encProps',
157
+
encryptedSlots: 'encSlots',
158
+
});
159
+
constresult=awaitgetRequestData(req);
160
+
assert.ok(
161
+
!(resultinstanceofResponse),
162
+
`Expected RenderOptions but got Response with status ${resultinstanceofResponse ? result.status : 'N/A'} — inherited 'slots' should not trigger rejection`,
163
+
);
164
+
}finally{
165
+
deleteObject.prototype.slots;
166
+
}
167
+
});
168
+
169
+
it('only checks own properties for `componentExport` validation',async()=>{
170
+
// Temporarily pollute Object.prototype to simulate inherited properties
171
+
Object.prototype.componentExport='default';
172
+
try{
173
+
constreq=makePostRequest({
174
+
encryptedComponentExport: 'encExport',
175
+
encryptedProps: 'encProps',
176
+
encryptedSlots: 'encSlots',
177
+
});
178
+
constresult=awaitgetRequestData(req);
179
+
assert.ok(
180
+
!(resultinstanceofResponse),
181
+
`Expected RenderOptions but got Response with status ${resultinstanceofResponse ? result.status : 'N/A'} — inherited 'componentExport' should not trigger rejection`,
0 commit comments