# shana

> Testing utilities for Cloud Functions.

Latest version **0.1.2** (published 2018-04-04) · MIT license · 0 weekly downloads

## Install

```sh
npm install shana
pnpm add shana
yarn add shana
bun add shana
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.2 |
| Published | 2018-04-04 |
| First published | 2018-02-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 1 |
| Unpacked size | 214.6 KB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| Author | star__hoshi |
| Maintainers | star__hoshi |
| Keywords | firebase, forestore, cloudfunctions |

## Links

- npm: https://www.npmjs.com/package/shana
- Repository: https://github.com/starhoshi/Shana
- Homepage: https://github.com/starhoshi/Shana#readme
- Issues: https://github.com/starhoshi/Shana/issues
- npm.io page: https://npm.io/package/shana

## Dependencies (1)

- [@google-cloud/firestore](https://npm.io/package/@google-cloud/firestore.md) ^0.13.1

## Recent versions

- 0.1.2 (latest) — 2018-04-04
- 0.1.1 — 2018-03-14
- 0.1.0 — 2018-02-14

## README

# Shana [![npm version](https://badge.fury.io/js/shana.svg)](https://badge.fury.io/js/shana) [![Build Status](https://travis-ci.org/starhoshi/Shana.svg?branch=master)](https://travis-ci.org/starhoshi/Shana) [![Codacy Badge](https://api.codacy.com/project/badge/Grade/8dabe6672f8c44409b283e4be1c1c012)](https://www.codacy.com/app/kensuke1751/Shana?utm_source=github.com&amp;utm_medium=referral&amp;utm_content=starhoshi/Shana&amp;utm_campaign=Badge_Grade) [![License: MIT](https://img.shields.io/badge/License-MIT-green.svg)](https://opensource.org/licenses/MIT)

Testing utilities for Cloud Functions.

## Observe update event with timeout

```ts
import * as Shana from 'shana'

test('user.name is Yukari Hirai', () => {
  // fire Cloud Functions
  ...

  observe<User>(userReference, (user, resolve, reject)=> {
    if (user.name === 'Yukari Hirai'){
      return resolve()
    } else if (user.name === 'Kazumi Yoshida') {
      return reject()
    }
  }, 20000)
})
```

---
_Source: https://npm.io/package/shana · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
