mirror of
https://github.com/iptv-org/epg.git
synced 2025-05-10 09:00:07 -04:00
Update pbsguam.org
This commit is contained in:
parent
69be299373
commit
0b1fed6d29
3 changed files with 3 additions and 13 deletions
|
@ -6,9 +6,6 @@ dayjs.extend(isBetween)
|
|||
module.exports = {
|
||||
site: 'pbsguam.org',
|
||||
url: 'https://pbsguam.org/calendar/',
|
||||
logo({ channel }) {
|
||||
return channel.logo
|
||||
},
|
||||
parser: function ({ content, date }) {
|
||||
let programs = []
|
||||
const items = parseItems(content, date)
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
// npx epg-grabber --config=sites/pbsguam.org/pbsguam.org.config.js --channels=sites/pbsguam.org/pbsguam.org_gu.channels.xml --output=.gh-pages/guides/gu/pbsguam.org.epg.xml --days=2
|
||||
|
||||
const { parser, url, logo } = require('./pbsguam.org.config.js')
|
||||
const { parser, url } = require('./pbsguam.org.config.js')
|
||||
const dayjs = require('dayjs')
|
||||
const utc = require('dayjs/plugin/utc')
|
||||
const customParseFormat = require('dayjs/plugin/customParseFormat')
|
||||
|
@ -10,20 +10,13 @@ dayjs.extend(utc)
|
|||
const date = dayjs.utc('2021-11-25', 'YYYY-MM-DD').startOf('d')
|
||||
const channel = {
|
||||
site_id: '#',
|
||||
xmltv_id: 'KGTF.us',
|
||||
logo: 'https://pbsguam.org/wp-content/uploads/sites/10/2021/09/pbs-guam-blue.png'
|
||||
xmltv_id: 'KGTF.us'
|
||||
}
|
||||
|
||||
it('can generate valid url', () => {
|
||||
expect(url).toBe('https://pbsguam.org/calendar/')
|
||||
})
|
||||
|
||||
it('can get logo url', () => {
|
||||
expect(logo({ channel })).toBe(
|
||||
'https://pbsguam.org/wp-content/uploads/sites/10/2021/09/pbs-guam-blue.png'
|
||||
)
|
||||
})
|
||||
|
||||
it('can parse response', () => {
|
||||
const content = `<!DOCTYPE html><html lang="en-US"> <head></head> <body> <script type='text/javascript' id='wcs-main-js-extra'>
|
||||
/* <![CDATA[ */
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<site site="pbsguam.org">
|
||||
<channels>
|
||||
<channel lang="en" xmltv_id="KGTF.us" site_id="#" logo="https://pbsguam.org/wp-content/uploads/sites/10/2021/09/pbs-guam-blue.png">PBS Guam (KGTF) Hagåtña, Guam</channel>
|
||||
<channel lang="en" xmltv_id="KGTF.us" site_id="#">PBS Guam (KGTF) Hagåtña, Guam</channel>
|
||||
</channels>
|
||||
</site>
|
Loading…
Add table
Add a link
Reference in a new issue