File size: 482 Bytes
68465df
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
import {shouldUseMentraLiveNativeCapture} from "./buttonCapturePolicy"

describe("Mentra Live button capture policy", () => {
  it("uses native photo/video capture when no miniapp subscribes to button presses", () => {
    expect(shouldUseMentraLiveNativeCapture([])).toBe(true)
  })

  it("routes button presses to miniapps when at least one active subscriber exists", () => {
    expect(shouldUseMentraLiveNativeCapture(["com.example.subscriber"])).toBe(false)
  })
})