• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

nikelborm / fetch-github-folder / 12822769545

17 Jan 2025 04:38AM UTC coverage: 55.811%. Remained the same
12822769545

push

github

nikelborm
quick save: Fri Jan 17 06:13:09 MSK 2025

52 of 63 branches covered (82.54%)

Branch coverage included in aggregate %.

27 of 72 new or added lines in 4 files covered. (37.5%)

9 existing lines in 2 files now uncovered.

337 of 634 relevant lines covered (53.15%)

2.37 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/writeFileStreamToDestinationPath.ts
NEW
1
import { Effect, gen, tryPromise } from 'effect/Effect';
×
2
import { createWriteStream } from 'node:fs';
3
import { Readable } from 'node:stream';
4
import { pipeline } from 'node:stream/promises';
5
import { OutputConfigTag } from './config.js';
6
import { TaggedErrorVerifyingCause } from './TaggedErrorVerifyingCause.js';
7

NEW
8
export const writeFileStreamToDestinationPath = <E, R>(
×
NEW
9
  self: Effect<Readable, E, R>,
×
10
) =>
NEW
11
  gen(function* () {
×
NEW
12
    const fileStream = yield* self;
×
13

NEW
14
    const {
×
NEW
15
      localPathAtWhichEntityFromRepoWillBeAvailable:
×
NEW
16
        localDownloadedFilePath,
×
NEW
17
    } = yield* OutputConfigTag;
×
18

NEW
19
    yield* tryPromise({
×
NEW
20
      try: signal =>
×
NEW
21
        pipeline(fileStream, createWriteStream(localDownloadedFilePath), {
×
NEW
22
          signal,
×
NEW
23
        }),
×
NEW
24
      catch: cause =>
×
NEW
25
        new FailedToWriteFileStreamToDestinationPath({ cause }),
×
NEW
26
    });
×
NEW
27
  });
×
28

NEW
29
export class FailedToWriteFileStreamToDestinationPath extends TaggedErrorVerifyingCause<{
×
30
  cause: unknown;
NEW
31
}>()(
×
NEW
32
  'FailedToWriteFileStreamToDestinationPath',
×
NEW
33
  'Error: Failed to write file stream to destination path',
×
NEW
34
) {}
×
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc