Skip to content

Commit

Permalink
Add vimeo test
Browse files Browse the repository at this point in the history
  • Loading branch information
Kikobeats committed Dec 10, 2017
1 parent a103ea4 commit 3e9eff2
Show file tree
Hide file tree
Showing 3 changed files with 1,134 additions and 0 deletions.
12 changes: 12 additions & 0 deletions __snapshots__/index.js.snap-shot
Original file line number Diff line number Diff line change
Expand Up @@ -789,3 +789,15 @@ exports['zdnet 1'] = {
"title": "Email security startup Agari raises $22 million to help enterprises fight phishing attacks | ZDNet",
"url": "http://www.zdnet.com/article/email-security-startup-agari-raises-22-million-to-help-enterprises-fight-phishing-attacks"
}

exports['vimeo 1'] = {
"author": null,
"date": null,
"description": "- Client: OGN (CJ E&M) - Producer: Yeonjung Hong - Creative Director: Youngmin Kim - Motion Design: Youngmin Kim, Gyuhwan Yu, Dahee Ahn - Sound Design: Stone…",
"image": "https://i.vimeocdn.com/filter/overlay?src0=https://i.vimeocdn.com/video/613524460_1280x720.webp&src1=https://f.vimeocdn.com/images_v6/share/play_icon_overlay.png",
"logo": "https://i.vimeocdn.com/favicon/main-touch_180",
"publisher": "Vimeo",
"title": "Overwatch APEX Season2 Title",
"url": "https://vimeo.com/200104989"
}

18 changes: 18 additions & 0 deletions test/web/vimeo/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
'use strict'

const snapshot = require('snap-shot')
const {promisify} = require('util')
const {resolve} = require('path')

const fs = require('fs')

const getMetaData = require('../../..')
const readFile = promisify(fs.readFile)

const url = 'https://vimeo.com/200104989'

it('vimeo', async () => {
const html = await readFile(resolve(__dirname, 'input.html'))
const metadata = await getMetaData({html, url})
snapshot(metadata)
})
Loading

0 comments on commit 3e9eff2

Please sign in to comment.