@sprucelabs/spruce-cli
Version:
Command line interface for building Spruce skills.
25 lines (21 loc) • 887 B
Plain Text
import { AbstractSpruceFixtureTest } from '@sprucelabs/spruce-test-fixtures'
import { assert } from '@sprucelabs/test-utils'
import HomeIntegrationsStore from '../../stores/HomeIntegrations.store'
import EventFaker from './EventFaker'
export default class AbstractGoogleTest extends AbstractSpruceFixtureTest {
protected eventFaker!: EventFaker
private homeIntegrations!: HomeIntegrationsStore
protected async beforeEach(): Promise<void> {
await super.beforeEach()
this.eventFaker = new EventFaker()
this.homeIntegrations = await this.stores.getStore('homeIntegrations')
}
protected async getFirstHomeIntegration() {
const match = await this.homeIntegrations.findOne(
{},
{ shouldIncludePrivateFields: true }
)
assert.isTruthy(match, 'No home integration found')
return match
}
}