Update mtel.ba

This commit is contained in:
Aleksandr Statciuk 2022-02-01 05:17:52 +03:00
parent ec68186710
commit 1458e7f298
2 changed files with 1 additions and 12 deletions

View file

@ -15,11 +15,6 @@ module.exports = {
'X-Requested-With': 'XMLHttpRequest' 'X-Requested-With': 'XMLHttpRequest'
} }
}, },
logo({ content, channel }) {
const data = parseContent(content, channel)
return data ? data.image : null
},
parser: function ({ content, channel }) { parser: function ({ content, channel }) {
let programs = [] let programs = []
const items = parseItems(content, channel) const items = parseItems(content, channel)

View file

@ -1,6 +1,6 @@
// npx epg-grabber --config=sites/mtel.ba/mtel.ba.config.js --channels=sites/mtel.ba/mtel.ba_ba.channels.xml --output=.gh-pages/guides/ba/mtel.ba.epg.xml --days=2 // npx epg-grabber --config=sites/mtel.ba/mtel.ba.config.js --channels=sites/mtel.ba/mtel.ba_ba.channels.xml --output=.gh-pages/guides/ba/mtel.ba.epg.xml --days=2
const { parser, url, request, logo } = require('./mtel.ba.config.js') const { parser, url, request } = require('./mtel.ba.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')
@ -26,12 +26,6 @@ it('can generate valid request headers', () => {
}) })
}) })
it('can get logo url', () => {
expect(logo({ content, channel })).toBe(
'https://mtel.ba/oec/images/tv_channels/c3556aa629b00325aaaea622abfb1070.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([