mirror of
https://github.com/iptv-org/epg.git
synced 2025-05-12 01:50:07 -04:00
Update tvim.tv
This commit is contained in:
parent
a2aafd65ef
commit
4523dba019
2 changed files with 1 additions and 9 deletions
|
@ -7,9 +7,6 @@ module.exports = {
|
||||||
channel.site_id
|
channel.site_id
|
||||||
}&server_time=true`
|
}&server_time=true`
|
||||||
},
|
},
|
||||||
logo({ channel }) {
|
|
||||||
return `https://mobile-api.tvim.tv/images/channels/120x60px/${channel.site_id}.png`
|
|
||||||
},
|
|
||||||
parser: function ({ content, channel, date }) {
|
parser: function ({ content, channel, date }) {
|
||||||
let programs = []
|
let programs = []
|
||||||
const items = parseItems(content)
|
const items = parseItems(content)
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
// npx epg-grabber --config=sites/tvim.tv/tvim.tv.config.js --channels=sites/tvim.tv/tvim.tv_xk.channels.xml --days=2 --output=.gh-pages/guides/xk/tvim.tv.epg.xml
|
// npx epg-grabber --config=sites/tvim.tv/tvim.tv.config.js --channels=sites/tvim.tv/tvim.tv_xk.channels.xml --days=2 --output=.gh-pages/guides/xk/tvim.tv.epg.xml
|
||||||
|
|
||||||
const { parser, url, logo } = require('./tvim.tv.config.js')
|
const { parser, url } = require('./tvim.tv.config.js')
|
||||||
const dayjs = require('dayjs')
|
const dayjs = require('dayjs')
|
||||||
const utc = require('dayjs/plugin/utc')
|
const utc = require('dayjs/plugin/utc')
|
||||||
const customParseFormat = require('dayjs/plugin/customParseFormat')
|
const customParseFormat = require('dayjs/plugin/customParseFormat')
|
||||||
|
@ -18,11 +18,6 @@ it('can generate valid url', () => {
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
|
||||||
it('can get logo url', () => {
|
|
||||||
const result = logo({ channel })
|
|
||||||
expect(result).toBe('https://mobile-api.tvim.tv/images/channels/120x60px/T7.png')
|
|
||||||
})
|
|
||||||
|
|
||||||
it('can parse response', () => {
|
it('can parse response', () => {
|
||||||
const result = parser({ date, channel, content })
|
const result = parser({ date, channel, content })
|
||||||
expect(result).toMatchObject([
|
expect(result).toMatchObject([
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue