Example #1
0
    def test_get_music_section(self):
        # Adding response.
        self.add_response_get_music_section()

        # Test if section key is "2" out of the mocking data.
        self.assertEqual(
            get_music_section(self.config['plex']['host'],
                              self.config['plex']['port']), '2')
Example #2
0
    def test_get_music_section(self):
        # Adding response.
        self.add_response_get_music_section()

        # Test if section key is "2" out of the mocking data.
        self.assertEqual(get_music_section(
            self.config['plex']['host'],
            self.config['plex']['port']), '2')
Example #3
0
    def test_get_named_music_section(self):
        # Adding response.
        self.add_response_get_music_section('My Music Library')

        self.assertEqual(get_music_section(
            self.config['plex']['host'],
            self.config['plex']['port'],
            self.config['plex']['token'],
            'My Music Library'), '2')
Example #4
0
    def test_get_named_music_section(self):
        # Adding response.
        self.add_response_get_music_section('My Music Library')

        self.assertEqual(
            get_music_section(self.config['plex']['host'],
                              self.config['plex']['port'],
                              self.config['plex']['token'],
                              'My Music Library'), '2')
Example #5
0
    def test_get_music_section(self):
        # Adding response.
        self.add_response_get_music_section()

        # Test if section key is "2" out of the mocking data.
        self.assertEqual(
            get_music_section(self.config['plex']['host'],
                              self.config['plex']['port'],
                              self.config['plex']['token'],
                              self.config['plex']['library_name'].get(),
                              self.config['plex']['secure'],
                              self.config['plex']['ignore_cert_errors']), '2')
Example #6
0
    def test_get_named_music_section(self):
        # Adding response.
        self.add_response_get_music_section("My Music Library")

        self.assertEqual(
            get_music_section(
                self.config["plex"]["host"],
                self.config["plex"]["port"],
                self.config["plex"]["token"],
                "My Music Library",
            ),
            "2",
        )
Example #7
0
    def test_get_music_section(self):
        # Adding response.
        self.add_response_get_music_section()

        # Test if section key is "2" out of the mocking data.
        self.assertEqual(
            get_music_section(
                self.config["plex"]["host"],
                self.config["plex"]["port"],
                self.config["plex"]["token"],
                self.config["plex"]["library_name"].get(),
            ),
            "2",
        )