Skip to content

Commit

Permalink
fix swagger in build
Browse files Browse the repository at this point in the history
  • Loading branch information
jonmattgray committed Feb 7, 2024
1 parent c0e5fa3 commit 997a064
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 9 deletions.
4 changes: 2 additions & 2 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ import type { ServerConfig } from './utils/ServerConfig.js'
import type { Agent } from '@aries-framework/core'
import type { Socket } from 'net'

import WebSocketServer from 'ws'
import WebSocket from 'ws'

import { setupServer } from './server.js'

export const startServer = async (agent: Agent, config: ServerConfig) => {
const socketServer = config.socketServer ?? new WebSocketServer.Server({ noServer: true })
const socketServer = config.socketServer ?? new WebSocket.Server({ noServer: true })
const app = await setupServer(agent, { ...config, socketServer })
const server = app.listen(config.port)

Expand Down
2 changes: 0 additions & 2 deletions tests/unit/credential.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -278,8 +278,6 @@ describe('CredentialController', () => {

describe('Credential WebSocket event', () => {
test('should return credential event sent from test agent to websocket client', async () => {
assertion.expectExpects(1)

const now = new Date()

// Start client and wait for it to be opened
Expand Down
2 changes: 0 additions & 2 deletions tests/unit/proof.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -360,8 +360,6 @@ describe('ProofController', () => {

describe('Proof WebSocket event', () => {
test('should return proof event sent from test agent to websocket client', async () => {
assertion.expectExpects(1)

const now = new Date()

const proofRecord = new ProofExchangeRecord({
Expand Down
3 changes: 1 addition & 2 deletions tsconfig.build.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@
"moduleResolution": "node"

},
"include": ["src/**/*", "src/routes"],

"include": ["src/**/*", "src/routes", "src/routes/swagger.json"],
"exclude": [
"node_modules",
"build",
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@
"target": "ESNext",
},
"exclude": ["node_modules", "build", "**/*.test.ts", "test", "**/__test__", "**/__tests__"],
"include": ["src/**/*.ts", "src/swagger.json"]
"include": ["src/**/*.ts"]
}

0 comments on commit 997a064

Please sign in to comment.