mirror of
https://github.com/4gray/iptvnator.git
synced 2026-10-08 17:06:15 -08:00
test: fix tests
This commit is contained in:
4 files changed
+26
-18
No files matched your search
+16
-12
@@ -99,12 +99,14 @@ describe('ChannelListContainerComponent', () => {
|
||||
component.groupedChannels[
|
||||
MOCKED_PLAYLIST.playlist.items[0].group.title
|
||||
][0]
|
||||
).toEqual({
|
||||
id: MOCKED_PLAYLIST.playlist.items[0].url,
|
||||
name: MOCKED_PLAYLIST.playlist.items[0].name,
|
||||
group: MOCKED_PLAYLIST.playlist.items[0].group,
|
||||
url: MOCKED_PLAYLIST.playlist.items[0].url,
|
||||
});
|
||||
).toEqual(
|
||||
expect.objectContaining({
|
||||
id: MOCKED_PLAYLIST.playlist.items[0].url,
|
||||
name: MOCKED_PLAYLIST.playlist.items[0].name,
|
||||
group: MOCKED_PLAYLIST.playlist.items[0].group,
|
||||
url: MOCKED_PLAYLIST.playlist.items[0].url,
|
||||
})
|
||||
);
|
||||
|
||||
// check second group
|
||||
expect(
|
||||
@@ -116,12 +118,14 @@ describe('ChannelListContainerComponent', () => {
|
||||
component.groupedChannels[
|
||||
MOCKED_PLAYLIST.playlist.items[2].group.title
|
||||
][0]
|
||||
).toEqual({
|
||||
id: MOCKED_PLAYLIST.playlist.items[2].url,
|
||||
name: MOCKED_PLAYLIST.playlist.items[2].name,
|
||||
group: MOCKED_PLAYLIST.playlist.items[2].group,
|
||||
url: MOCKED_PLAYLIST.playlist.items[2].url,
|
||||
});
|
||||
).toEqual(
|
||||
expect.objectContaining({
|
||||
id: MOCKED_PLAYLIST.playlist.items[2].url,
|
||||
name: MOCKED_PLAYLIST.playlist.items[2].name,
|
||||
group: MOCKED_PLAYLIST.playlist.items[2].group,
|
||||
url: MOCKED_PLAYLIST.playlist.items[2].url,
|
||||
})
|
||||
);
|
||||
});
|
||||
|
||||
it('should set favorites list', () => {
|
||||
|
||||
@@ -4,7 +4,7 @@ import { EpgProgram } from '../../models/epg-program.model';
|
||||
import * as moment from 'moment';
|
||||
import { ElectronService } from '../../../services/electron.service';
|
||||
import { EPG_GET_PROGRAM_DONE } from '../../../shared/ipc-commands';
|
||||
import { ChannelStore } from 'app/state';
|
||||
import { ChannelStore } from '../../../state';
|
||||
|
||||
interface EpgData {
|
||||
channel: EpgChannel;
|
||||
|
||||
@@ -4,7 +4,7 @@ import { EPG_GET_PROGRAM } from '../shared/ipc-commands';
|
||||
import { ElectronService } from '../services/electron.service';
|
||||
import { Channel } from './channel.model';
|
||||
import * as moment from 'moment';
|
||||
import { EpgProgram } from 'app/player/models/epg-program.model';
|
||||
import { EpgProgram } from '../player/models/epg-program.model';
|
||||
|
||||
export interface ChannelState extends EntityState<Channel> {
|
||||
active: Channel;
|
||||
|
||||
@@ -18,7 +18,8 @@
|
||||
"language": "",
|
||||
"country": "",
|
||||
"logo": "",
|
||||
"url": ""
|
||||
"url": "",
|
||||
"rec": ""
|
||||
},
|
||||
"group": {
|
||||
"title": "news\r"
|
||||
@@ -38,7 +39,8 @@
|
||||
"language": "",
|
||||
"country": "",
|
||||
"logo": "",
|
||||
"url": ""
|
||||
"url": "",
|
||||
"rec": ""
|
||||
},
|
||||
"group": {
|
||||
"title": "news\r"
|
||||
@@ -58,7 +60,8 @@
|
||||
"language": "",
|
||||
"country": "",
|
||||
"logo": "",
|
||||
"url": ""
|
||||
"url": "",
|
||||
"rec": ""
|
||||
},
|
||||
"group": {
|
||||
"title": "category 2\r"
|
||||
@@ -78,7 +81,8 @@
|
||||
"language": "",
|
||||
"country": "",
|
||||
"logo": "",
|
||||
"url": ""
|
||||
"url": "",
|
||||
"rec": ""
|
||||
},
|
||||
"group": {
|
||||
"title": "category 2\r"
|
||||
|
||||
Reference in new issue
Block a user