11cb0ef41Sopenharmony_ci'use strict'; 21cb0ef41Sopenharmony_ci 31cb0ef41Sopenharmony_ci// Test that the setter for http.IncomingMessage,prototype.connection sets the 41cb0ef41Sopenharmony_ci// socket property too. 51cb0ef41Sopenharmony_cirequire('../common'); 61cb0ef41Sopenharmony_ci 71cb0ef41Sopenharmony_ciconst assert = require('assert'); 81cb0ef41Sopenharmony_ciconst http = require('http'); 91cb0ef41Sopenharmony_ci 101cb0ef41Sopenharmony_ciconst incomingMessage = new http.IncomingMessage(); 111cb0ef41Sopenharmony_ci 121cb0ef41Sopenharmony_ciassert.strictEqual(incomingMessage.connection, undefined); 131cb0ef41Sopenharmony_ciassert.strictEqual(incomingMessage.socket, undefined); 141cb0ef41Sopenharmony_ci 151cb0ef41Sopenharmony_ciincomingMessage.connection = 'fhqwhgads'; 161cb0ef41Sopenharmony_ci 171cb0ef41Sopenharmony_ciassert.strictEqual(incomingMessage.connection, 'fhqwhgads'); 181cb0ef41Sopenharmony_ciassert.strictEqual(incomingMessage.socket, 'fhqwhgads'); 19