mirror of
https://github.com/nodejs/node.git
synced 2025-05-04 23:42:17 +00:00

Correct alignment on variable assignments that span multiple lines in preparation for lint rule to enforce such alignment. PR-URL: https://github.com/nodejs/node/pull/6242 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Johan Bergström <bugs@bergstroem.nu> Reviewed-By: James M Snell <jasnell@gmail.com>
27 lines
713 B
JavaScript
27 lines
713 B
JavaScript
'use strict';
|
|
|
|
require('../common');
|
|
const assert = require('assert');
|
|
const tls = require('tls');
|
|
|
|
const singles = 'C=US\nST=CA\nL=SF\nO=Node.js Foundation\nOU=Node.js\n' +
|
|
'CN=ca1\nemailAddress=ry@clouds.org';
|
|
const singlesOut = tls.parseCertString(singles);
|
|
assert.deepEqual(singlesOut, {
|
|
C: 'US',
|
|
ST: 'CA',
|
|
L: 'SF',
|
|
O: 'Node.js Foundation',
|
|
OU: 'Node.js',
|
|
CN: 'ca1',
|
|
emailAddress: 'ry@clouds.org'
|
|
});
|
|
|
|
const doubles = 'OU=Domain Control Validated\nOU=PositiveSSL Wildcard\n' +
|
|
'CN=*.nodejs.org';
|
|
const doublesOut = tls.parseCertString(doubles);
|
|
assert.deepEqual(doublesOut, {
|
|
OU: [ 'Domain Control Validated', 'PositiveSSL Wildcard' ],
|
|
CN: '*.nodejs.org'
|
|
});
|