Skip to content

Commit

Permalink
ran make lint-fix
Browse files Browse the repository at this point in the history
  • Loading branch information
pravusjif committed Oct 31, 2024
1 parent 08fa539 commit 630cb31
Showing 1 changed file with 14 additions and 11 deletions.
25 changes: 14 additions & 11 deletions test/ecs/events/system.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
import { Engine, Entity, IEngine, components, PointerEventType, InputAction } from '../../../packages/@dcl/ecs/src'
import { createInputSystem } from '../../../packages/@dcl/ecs/src/engine/input'
import { createPointerEventsSystem, getDefaultOpts, PointerEventsSystem } from '../../../packages/@dcl/ecs/src/systems/events'
import {
createPointerEventsSystem,
getDefaultOpts,
PointerEventsSystem
} from '../../../packages/@dcl/ecs/src/systems/events'
import { createTestPointerDownCommand } from './utils'

let engine: IEngine
Expand Down Expand Up @@ -78,20 +82,19 @@ describe('Events System', () => {
const entity = engine.addEntity()
const PointerEvents = components.PointerEvents(engine)
let counter = 0
EventsSystem.onPointerDown(
entity,
() => {
counter += 1
}
)
EventsSystem.onPointerDown(entity, () => {
counter += 1
})
fakePointer(entity, PointerEventType.PET_DOWN)
await engine.update(1)
expect(counter).toBe(1)
expect(PointerEvents.getOrNull(entity)).toMatchObject({
'pointerEvents': [{
'eventInfo': getDefaultOpts(),
'eventType': 1
}]
pointerEvents: [
{
eventInfo: getDefaultOpts(),
eventType: 1
}
]
})
})

Expand Down

0 comments on commit 630cb31

Please sign in to comment.