Skip to content

Commit 1135239

Browse files
CLDSRV-835: Add newlines to log lines
1 parent eedcd6b commit 1135239

File tree

1 file changed

+21
-22
lines changed

1 file changed

+21
-22
lines changed

tests/functional/aws-node-sdk/test/object/copyPart.js

Lines changed: 21 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -339,14 +339,13 @@ describe('Object Part Copy', () => {
339339
PartNumber: i,
340340
});
341341
}
342-
process.stdout.write('about to put parts');
342+
process.stdout.write('about to put parts\n');
343343
return Promise.all(partUploads);
344344
}).catch(err => {
345-
process.stdout.write(`Error putting parts in ' +
346-
'MPU beforeEach: ${err}\n`);
345+
process.stdout.write(`Error putting parts in MPU beforeEach: ${err}\n`);
347346
throw err;
348347
}).then(() => {
349-
process.stdout.write('completing mpu');
348+
process.stdout.write('completing mpu\n');
350349
return s3.send(new CompleteMultipartUploadCommand({
351350
Bucket: sourceBucketName,
352351
Key: sourceMpuKey,
@@ -356,7 +355,7 @@ describe('Object Part Copy', () => {
356355
},
357356
}));
358357
}).then(() => {
359-
process.stdout.write('finished completing mpu');
358+
process.stdout.write('finished completing mpu\n');
360359
}).catch(err => {
361360
process.stdout.write(`Error in MPU beforeEach: ${err}\n`);
362361
throw err;
@@ -377,7 +376,7 @@ describe('Object Part Copy', () => {
377376

378377
it('should copy a part from a source bucket to a different ' +
379378
'destination bucket', () => {
380-
process.stdout.write('Entered first mpu test');
379+
process.stdout.write('Entered first mpu test\n');
381380
return s3.send(new UploadPartCopyCommand({
382381
Bucket: destBucketName,
383382
Key: destObjName,
@@ -393,7 +392,7 @@ describe('Object Part Copy', () => {
393392

394393
it('should copy two parts from a source bucket to a different ' +
395394
'destination bucket and complete the MPU', () => {
396-
process.stdout.write('Putting first part in MPU test');
395+
process.stdout.write('Putting first part in MPU test\n');
397396
return s3.send(new UploadPartCopyCommand({
398397
Bucket: destBucketName,
399398
Key: destObjName,
@@ -404,7 +403,7 @@ describe('Object Part Copy', () => {
404403
assert.strictEqual(res.CopyPartResult.ETag, totalMpuObjectHash);
405404
assert(res.CopyPartResult.LastModified);
406405
}).then(() => {
407-
process.stdout.write('Putting second part in MPU test');
406+
process.stdout.write('Putting second part in MPU test\n');
408407
return s3.send(new UploadPartCopyCommand({
409408
Bucket: destBucketName,
410409
Key: destObjName,
@@ -415,7 +414,7 @@ describe('Object Part Copy', () => {
415414
assert.strictEqual(res.CopyPartResult.ETag, totalMpuObjectHash);
416415
assert(res.CopyPartResult.LastModified);
417416
}).then(() => {
418-
process.stdout.write('Completing MPU');
417+
process.stdout.write('Completing MPU\n');
419418
return s3.send(new CompleteMultipartUploadCommand({
420419
Bucket: destBucketName,
421420
Key: destObjName,
@@ -443,7 +442,7 @@ describe('Object Part Copy', () => {
443442
it('should copy two parts with range headers from a source ' +
444443
'bucket to a different destination bucket and ' +
445444
'complete the MPU', () => {
446-
process.stdout.write('Putting first part in MPU range test');
445+
process.stdout.write('Putting first part in MPU range test\n');
447446
const part1ETag = '"b1e0d096c8f0670c5367d131e392b84a"';
448447
const part2ETag = '"a2468d5c0ec2d4d5fc13b73beb63080a"';
449448
// combined ETag returned by AWS (combination of part ETags
@@ -461,7 +460,7 @@ describe('Object Part Copy', () => {
461460
assert.strictEqual(res.CopyPartResult.ETag, part1ETag);
462461
assert(res.CopyPartResult.LastModified);
463462
}).then(() => {
464-
process.stdout.write('Putting second part in MPU test');
463+
process.stdout.write('Putting second part in MPU test\n');
465464
return s3.send(new UploadPartCopyCommand({
466465
Bucket: destBucketName,
467466
Key: destObjName,
@@ -473,7 +472,7 @@ describe('Object Part Copy', () => {
473472
assert.strictEqual(res.CopyPartResult.ETag, part2ETag);
474473
assert(res.CopyPartResult.LastModified);
475474
}).then(() => {
476-
process.stdout.write('Completing MPU');
475+
process.stdout.write('Completing MPU\n');
477476
return s3.send(new CompleteMultipartUploadCommand({
478477
Bucket: destBucketName,
479478
Key: destObjName,
@@ -489,7 +488,7 @@ describe('Object Part Copy', () => {
489488
assert.strictEqual(res.Key, destObjName);
490489
assert.strictEqual(res.ETag, finalCombinedETag);
491490
}).then(() => {
492-
process.stdout.write('Getting new object');
491+
process.stdout.write('Getting new object\n');
493492
return s3.send(new GetObjectCommand({
494493
Bucket: destBucketName,
495494
Key: destObjName,
@@ -508,7 +507,7 @@ describe('Object Part Copy', () => {
508507
it('should overwrite an existing part by copying a part', () => {
509508
// AWS response etag for this completed MPU
510509
const finalObjETag = '"db77ebbae9e9f5a244a26b86193ad818-1"';
511-
process.stdout.write('Putting first part in MPU test');
510+
process.stdout.write('Putting first part in MPU test\n');
512511
return s3.send(new UploadPartCopyCommand({
513512
Bucket: destBucketName,
514513
Key: destObjName,
@@ -519,7 +518,7 @@ describe('Object Part Copy', () => {
519518
assert.strictEqual(res.CopyPartResult.ETag, totalMpuObjectHash);
520519
assert(res.CopyPartResult.LastModified);
521520
}).then(() => {
522-
process.stdout.write('Overwriting first part in MPU test');
521+
process.stdout.write('Overwriting first part in MPU test\n');
523522
return s3.send(new UploadPartCopyCommand({
524523
Bucket: destBucketName,
525524
Key: destObjName,
@@ -530,7 +529,7 @@ describe('Object Part Copy', () => {
530529
).then(res => {
531530
assert.strictEqual(res.CopyPartResult.ETag, etag);
532531
assert(res.CopyPartResult.LastModified);
533-
process.stdout.write('Completing MPU');
532+
process.stdout.write('Completing MPU\n');
534533
return s3.send(new CompleteMultipartUploadCommand({
535534
Bucket: destBucketName,
536535
Key: destObjName,
@@ -547,7 +546,7 @@ describe('Object Part Copy', () => {
547546
assert.strictEqual(res.ETag, finalObjETag);
548547
}).then(() => {
549548
process.stdout.write('Getting object put by MPU with ' +
550-
'overwrite part');
549+
'overwrite part\n');
551550
return s3.send(new GetObjectCommand({
552551
Bucket: destBucketName,
553552
Key: destObjName,
@@ -564,7 +563,7 @@ describe('Object Part Copy', () => {
564563
it('should not corrupt object if overwriting an existing part by copying a part ' +
565564
'while the MPU is being completed', async () => {
566565
const finalObjETag = '"db77ebbae9e9f5a244a26b86193ad818-1"';
567-
process.stdout.write('Putting first part in MPU test"');
566+
process.stdout.write('Putting first part in MPU test\n');
568567
const randomDestObjName = `copycatobject${Math.floor(Math.random() * 100000)}`;
569568

570569
const initiateRes = await s3.send(new CreateMultipartUploadCommand({
@@ -584,7 +583,7 @@ describe('Object Part Copy', () => {
584583
assert(res.CopyPartResult.LastModified);
585584

586585
process.stdout.write(
587-
'Overwriting first part in MPU test and completing MPU at the same time',
586+
'Overwriting first part in MPU test and completing MPU at the same time\n',
588587
);
589588
const [completeRes, uploadRes] = await Promise.all([
590589
s3.send(new CompleteMultipartUploadCommand({
@@ -623,7 +622,7 @@ describe('Object Part Copy', () => {
623622
assert.strictEqual(completeRes.Key, randomDestObjName);
624623
assert.strictEqual(completeRes.ETag, finalObjETag);
625624
process.stdout.write(
626-
'Getting object put by MPU with ' + 'overwrite part',
625+
'Getting object put by MPU with overwrite part\n',
627626
);
628627
const resGet = await s3
629628
.send(new GetObjectCommand({
@@ -761,15 +760,15 @@ describe('Object Part Copy', () => {
761760
let otherAccountUploadId;
762761

763762
beforeEach(() => {
764-
process.stdout.write('In other account before each');
763+
process.stdout.write('In other account before each\n');
765764
return otherAccountS3.send(new CreateBucketCommand({ Bucket:
766765
otherAccountBucket }))
767766
.catch(err => {
768767
process.stdout.write('Error creating other account ' +
769768
`bucket: ${err}\n`);
770769
throw err;
771770
}).then(() => {
772-
process.stdout.write('Initiating other account MPU');
771+
process.stdout.write('Initiating other account MPU\n');
773772
return otherAccountS3.send(new CreateMultipartUploadCommand({
774773
Bucket: otherAccountBucket,
775774
Key: otherAccountKey,

0 commit comments

Comments
 (0)