mirror of
https://github.com/iptv-org/epg.git
synced 2025-05-10 00:50:09 -04:00
Update programetv.ro
This commit is contained in:
parent
f7ce568a14
commit
7307a01895
2 changed files with 1 additions and 11 deletions
|
@ -16,11 +16,6 @@ module.exports = {
|
||||||
|
|
||||||
return `https://www.programetv.ro/post/${channel.site_id}/${daysOfWeek[day]}/`
|
return `https://www.programetv.ro/post/${channel.site_id}/${daysOfWeek[day]}/`
|
||||||
},
|
},
|
||||||
logo({ content }) {
|
|
||||||
const data = parseContent(content)
|
|
||||||
|
|
||||||
return data && data.station ? data.station.icon : null
|
|
||||||
},
|
|
||||||
parser: function ({ content }) {
|
parser: function ({ content }) {
|
||||||
let programs = []
|
let programs = []
|
||||||
const data = parseContent(content)
|
const data = parseContent(content)
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
// npx epg-grabber --config=sites/programetv.ro/programetv.ro.config.js --channels=sites/programetv.ro/programetv.ro_ro.channels.xml --output=.gh-pages/guides/ro/programetv.ro.epg.xml --days=2
|
// npx epg-grabber --config=sites/programetv.ro/programetv.ro.config.js --channels=sites/programetv.ro/programetv.ro_ro.channels.xml --output=.gh-pages/guides/ro/programetv.ro.epg.xml --days=2
|
||||||
|
|
||||||
const { parser, url, logo } = require('./programetv.ro.config.js')
|
const { parser, url } = require('./programetv.ro.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')
|
||||||
|
@ -31,11 +31,6 @@ it('can generate valid url', () => {
|
||||||
expect(result).toBe('https://www.programetv.ro/post/pro-tv/duminica/')
|
expect(result).toBe('https://www.programetv.ro/post/pro-tv/duminica/')
|
||||||
})
|
})
|
||||||
|
|
||||||
it('can get logo url', () => {
|
|
||||||
const result = logo({ content })
|
|
||||||
expect(result).toBe('https://static.cinemagia.ro/img/tv_station/pro-tv.jpg')
|
|
||||||
})
|
|
||||||
|
|
||||||
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