Skip to content

Commit

Permalink
fix: disable wait for result
Browse files Browse the repository at this point in the history
  • Loading branch information
tomwwinter committed Jul 11, 2024
1 parent 5245a82 commit 6e88c34
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/app.controller.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ describe('AppController', () => {
await expect(testMail('[email protected]')).resolves.toBeTruthy();
});

it('should throw error if ERROR is written to log', async () => {
xit('should throw error if ERROR is written to log', async () => {
const res = firstValueFrom(controller.deployApp(deploymentData));
lines.next('some logs');
lines.next('ERROR my custom error');
Expand All @@ -169,7 +169,7 @@ describe('AppController', () => {
throw new Error('No error thrown');
});

it('should write arguments to file', () => {
xit('should write arguments to file', () => {
const res = firstValueFrom(controller.deployApp(deploymentData));

lines.next('DONE');
Expand Down
5 changes: 3 additions & 2 deletions src/app.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import { DeploymentInfo } from './deployment-info.dto';
import * as fs from 'fs';
import { HttpService } from '@nestjs/axios';
import { ConfigService } from '@nestjs/config';
import { catchError, mergeMap, Observable, Subject } from 'rxjs';
import { catchError, mergeMap, Observable, of, Subject } from 'rxjs';
import { Tail } from 'tail';

@Controller()
Expand Down Expand Up @@ -80,7 +80,8 @@ export class AppController {
const ws = fs.createWriteStream('dist/assets/arg-pipe');
ws.write(args);
ws.close();
return this.getResult();
return of(true);
// return this.getResult();
}

private getResult() {
Expand Down

0 comments on commit 6e88c34

Please sign in to comment.