Commit df762a7a authored by Léo-Paul Géneau's avatar Léo-Paul Géneau 👾

Update tests

Update tests to comply with commits:
- 904ef9ec (--no-rdoc and --no-ri
options deletion)
- c58aba06 (adds ruby executable path to commands)
parent 5ab66f71
...@@ -9,6 +9,7 @@ import shutil ...@@ -9,6 +9,7 @@ import shutil
import subprocess import subprocess
import tempfile import tempfile
import unittest import unittest
import re
from six import BytesIO from six import BytesIO
...@@ -117,7 +118,7 @@ class RubyGemsTests(unittest.TestCase): ...@@ -117,7 +118,7 @@ class RubyGemsTests(unittest.TestCase):
args = patches['check_output'].mock_calls[1][1] args = patches['check_output'].mock_calls[1][1]
self.assertEqual(args[0], [ self.assertEqual(args[0], [
None, 'install', '--no-rdoc', '--no-ri', 'ruby', None, 'install',
'--bindir=%s/rubygems/bin' % path, '--bindir=%s/rubygems/bin' % path,
'sass', '--' 'sass', '--'
]) ])
...@@ -198,8 +199,8 @@ class RubyGemsTests(unittest.TestCase): ...@@ -198,8 +199,8 @@ class RubyGemsTests(unittest.TestCase):
recipe.install() recipe.install()
args = patches['check_output'].mock_calls[0][1] args = patches['check_output'].mock_calls[0][1]
self.assertEqual(args[0], [ for arg in args[0]:
'%s/rubygems/bin/gem' % path, 'install', '--no-rdoc', '--no-ri', matched = re.search('^--version.*$', arg)
'--bindir=%s/rubygems/bin' % path, if matched:
'sass', '--version=1.0', '--' self.assertEqual(matched.group(), '--version=1.0')
]) break
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment