Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
stsewd committed Dec 18, 2020
1 parent 709545d commit 4f08404
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion readthedocs/rtd_tests/tests/test_doc_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,10 @@ def test_get_theme_name_with_feature_flag(self, checkout_path, run):
self.assertEqual(builder.get_theme_name({}), 'readthedocs')
with patch('readthedocs.doc_builder.backends.mkdocs.yaml') as mock_yaml:
with patch('readthedocs.doc_builder.backends.mkdocs.MkdocsHTML.load_yaml_config') as mock_load_yaml_config:
mock_load_yaml_config.return_value = {'site_name': self.project.name}
mock_load_yaml_config.return_value = {
'site_name': self.project.name,
'docs_dir': tmpdir,
}
builder.append_conf()

mock_yaml.safe_dump.assert_called_once_with(
Expand All @@ -374,6 +377,7 @@ def test_get_theme_name_with_feature_flag(self, checkout_path, run):
mock_load_yaml_config.return_value = {
'site_name': self.project.name,
'theme': 'customtheme',
'docs_dir': tmpdir,
}
builder.append_conf()

Expand Down

0 comments on commit 4f08404

Please sign in to comment.