Esempio n. 1
0
    def test_sources_list(self):
        output = """*** CURRENT SOURCES ***

http://rubygems.org/
"""
        mock = MagicMock(return_value=output)
        with patch.object(gem, "_gem", new=mock):
            self.assertEqual(["http://rubygems.org/"], gem.sources_list())
Esempio n. 2
0
    def test_sources_list(self):
        output = '''*** CURRENT SOURCES ***

http://rubygems.org/
'''
        mock = MagicMock(return_value=output)
        with patch.object(gem, '_gem', new=mock):
            self.assertEqual(['http://rubygems.org/'], gem.sources_list())
Esempio n. 3
0
    def test_sources_list(self):
        output = """*** CURRENT SOURCES ***

http://rubygems.org/
"""
        mock = MagicMock(return_value=output)
        with patch.object(gem, "_gem", new=mock):
            self.assertEqual(["http://rubygems.org/"], gem.sources_list())
Esempio n. 4
0
    def test_sources_list(self):
        output = '''*** CURRENT SOURCES ***

http://rubygems.org/
'''
        mock = MagicMock(return_value=output)
        with patch.object(gem, '_gem', new=mock):
            self.assertEqual(
                ['http://rubygems.org/'], gem.sources_list())