Skip to content

Commit

Permalink
test(repo): convert tests to relative paths
Browse files Browse the repository at this point in the history
  • Loading branch information
jwulf committed Apr 7, 2024
1 parent 7386f3a commit f7578a7
Show file tree
Hide file tree
Showing 40 changed files with 54 additions and 86 deletions.
3 changes: 1 addition & 2 deletions src/__tests__/admin/admin.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import { EnvironmentSetup } from 'lib'

import { AdminApiClient } from '../../admin/index'
import { EnvironmentSetup } from '../../lib'

beforeAll(() => {
EnvironmentSetup.storeEnv()
Expand Down
4 changes: 2 additions & 2 deletions src/__tests__/lib/LosslessJsonParser.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import {
LosslessDto,
losslessParse,
losslessStringify,
} from 'lib'
import { ProcessInstanceStatistics } from 'operate/lib/OperateDto'
} from '../../lib'
import { ProcessInstanceStatistics } from '../../operate/lib/OperateDto'

test('LosslessJsonParser correctly handles nested Dtos', () => {
class DecisionInstanceOutput extends LosslessDto {
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/modeler/modeler.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { EnvironmentSetup } from 'lib'

import { EnvironmentSetup } from '../../lib'
import { ModelerApiClient } from '../../modeler/index'

beforeAll(() => {
Expand Down
5 changes: 2 additions & 3 deletions src/__tests__/operate/multitenancy/operate-mt.spec.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { delay, restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import { ZeebeGrpcClient } from 'zeebe'

import { delay, restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { OperateApiClient } from '../../../operate'
import { ZeebeGrpcClient } from '../../../zeebe'

jest.setTimeout(15000)
suppressZeebeLogging()
Expand Down
5 changes: 2 additions & 3 deletions src/__tests__/operate/operate.spec.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { EnvironmentSetup } from 'lib'
import { TestableOperateApiClient } from 'operate/lib/TestableOperateApiClient'

import { EnvironmentSetup } from '../../lib'
import { OperateApiClient } from '../../operate'
import { TestableOperateApiClient } from '../../operate/lib/TestableOperateApiClient'

beforeAll(() => {
EnvironmentSetup.storeEnv()
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/optimize/optimize.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { EnvironmentSetup } from 'lib'

import { EnvironmentSetup } from '../../lib'
import { OptimizeApiClient } from '../../optimize/lib/OptimizeApiClient'

beforeAll(() => {
Expand Down
9 changes: 4 additions & 5 deletions src/__tests__/tasklist/tasklist.integration.spec.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
import { join } from 'path'

import { OperateApiClient } from 'operate'
import { OperateApiClient } from '../../operate'
import { TasklistApiClient } from '../../tasklist/index'
import { ZeebeGrpcClient } from '../../zeebe'
import {
CreateProcessInstanceResponse,
DeployResourceResponse,
ProcessDeployment,
} from 'zeebe/types'

import { TasklistApiClient } from '../../tasklist/index'
import { ZeebeGrpcClient } from '../../zeebe'
} from '../../zeebe/types'

jest.setTimeout(25000) // increase timeout to allow Tasklist application to create tasks

Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/tasklist/tasklist.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { EnvironmentSetup } from 'lib'

import { EnvironmentSetup } from '../../lib'
import { TasklistApiClient } from '../../tasklist/index'

beforeAll(() => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'

Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Client-BrokenBpmn.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'

suppressZeebeLogging()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'

jest.setTimeout(10000)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import { DeployResourceResponse, ProcessDeployment } from 'zeebe/types'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import { DeployResourceResponse, ProcessDeployment } from '../../../zeebe/types'

jest.setTimeout(25000)

Expand Down
4 changes: 2 additions & 2 deletions src/__tests__/zeebe/integration/Client-DeleteResource.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import { ZeebeGrpcClient } from 'zeebe'
import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'

jest.setTimeout(20000)

Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Client-DeployProcess.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe/index'

process.env.ZEEBE_NODE_LOG_LEVEL = process.env.ZEEBE_NODE_LOG_LEVEL || 'NONE'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import fs from 'fs'

import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { BpmnParser, ZeebeGrpcClient } from '../../../zeebe/index'

process.env.ZEEBE_NODE_LOG_LEVEL = process.env.ZEEBE_NODE_LOG_LEVEL || 'NONE'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe/index'

beforeAll(() => suppressZeebeLogging())
Expand Down
4 changes: 2 additions & 2 deletions src/__tests__/zeebe/integration/Client-MessageStart.spec.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import { v4 as uuid } from 'uuid'
import { DeployResourceResponse, ProcessDeployment } from 'zeebe/types'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import { DeployResourceResponse, ProcessDeployment } from '../../../zeebe/types'

jest.setTimeout(45000)
let test1: DeployResourceResponse<ProcessDeployment>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import { DeployResourceResponse, ProcessDeployment } from 'zeebe/types'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe/index'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import { DeployResourceResponse, ProcessDeployment } from '../../../zeebe/types'

suppressZeebeLogging()

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe/index'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import { v4 as uuid } from 'uuid'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'

Expand Down
2 changes: 1 addition & 1 deletion src/__tests__/zeebe/integration/Client-ThrowError.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import { Duration } from 'typed-duration'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'

Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Client-integration.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe/index'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'

Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Client-onReady.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'

jest.setTimeout(30000)
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Client-setVariables.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import {
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Client-startProcess.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import { CreateProcessInstanceResponse } from '../../../zeebe/lib/interfaces-grpc-1.0'
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Topology.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'

suppressZeebeLogging()
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/TypeSurfaceAreaTest.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import { ZBWorkerTaskHandler } from 'zeebe/types'

import { ZeebeGrpcClient } from '../../../zeebe/index'
import { ZBWorkerTaskHandler } from '../../../zeebe/types'

jest.setTimeout(7000)

Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Worker-1.0-complete.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import { CreateProcessInstanceResponse } from '../../../zeebe/lib/interfaces-grpc-1.0'
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Worker-Dto.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { BigIntValue, Int64String, LosslessDto } from 'lib'

import { BigIntValue, Int64String, LosslessDto } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'

test("Let's test worker handler signatures", () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import { CreateProcessInstanceResponse } from '../../../zeebe/lib/interfaces-grpc-1.0'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import { CreateProcessInstanceResponse } from '../../../zeebe/lib/interfaces-grpc-1.0'
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Worker-Failure.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import {
Expand Down
2 changes: 1 addition & 1 deletion src/__tests__/zeebe/integration/Worker-LongPoll.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import * as uuid from 'uuid'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'

Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Worker-RaiseIncident.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'

Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Worker-fetchVariable.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import { CreateProcessInstanceResponse } from '../../../zeebe/lib/interfaces-grpc-1.0'
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Worker-integration.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { cancelProcesses } from '../../../zeebe/lib/cancelProcesses'
import { CreateProcessInstanceResponse } from '../../../zeebe/lib/interfaces-grpc-1.0'
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/integration/Worker-onReady.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'

jest.setTimeout(40000)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import { ZeebeGrpcClient } from 'zeebe'
import { DeployResourceResponse, ProcessDeployment } from 'zeebe/types'
import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe'
import { DeployResourceResponse, ProcessDeployment } from '../../../zeebe/types'

suppressZeebeLogging()
let res: DeployResourceResponse<ProcessDeployment>
Expand Down
3 changes: 1 addition & 2 deletions src/__tests__/zeebe/multitenancy/deployprocess-mt.spec.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { restoreZeebeLogging, suppressZeebeLogging } from 'lib'

import { restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { ZeebeGrpcClient } from '../../../zeebe/index'

const STORED_ENV = {}
Expand Down
6 changes: 3 additions & 3 deletions src/__tests__/zeebe/multitenancy/signalbroadcast-mt.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { delay, restoreZeebeLogging, suppressZeebeLogging } from 'lib'
import { OperateApiClient } from 'operate'
import { ZeebeGrpcClient } from 'zeebe'
import { delay, restoreZeebeLogging, suppressZeebeLogging } from '../../../lib'
import { OperateApiClient } from '../../../operate'
import { ZeebeGrpcClient } from '../../../zeebe'

jest.setTimeout(7000)
suppressZeebeLogging()
Expand Down

0 comments on commit f7578a7

Please sign in to comment.