Commit Graph

221 Commits

Author SHA1 Message Date
Jon Dufresne
22afc77c48 Python-3-only clean ups discovered by pyupgrade
https://github.com/asottile/pyupgrade

> A tool to automatically upgrade syntax for newer versions of the
> language.

- Drop u str prefix
- Drop base object inheritance
- Drop args to super()
- Use set literals
- Use dict comprehension
- Use set comprehension
2019-03-19 01:09:48 +09:00
Jon Dufresne
f210475489 Python-3-only clean ups discovered by pyupgrade
https://github.com/asottile/pyupgrade

> A tool to automatically upgrade syntax for newer versions of the
> language.

- Drop u str prefix
- Drop base object inheritance
- Drop args to super()
- Use set literals
- Use dict comprehension
- Use set comprehension
2019-03-17 12:58:03 -07:00
Takeshi KOMIYA
6698bd6b3f Fix #6178: i18n: Captions missing in translations for hidden TOCs 2019-03-17 17:19:33 +09:00
Takeshi KOMIYA
fb8838ee53 refactor: Use CatalogRepository instead of find_catalog_source_file() 2019-02-27 22:47:08 +09:00
Takeshi KOMIYA
90bf81bd37 test: Use get_doctree() to load doctree files 2019-02-17 20:27:48 +09:00
Takeshi KOMIYA
36d628929e Merge branch '1.8' 2019-01-26 13:40:19 +09:00
Takeshi KOMIYA
1182e7f6d2 refactor: compile .mo file only if needed on testing 2019-01-20 11:51:23 +09:00
Takeshi KOMIYA
c4c878303f encoding keyword for path.text() and path.write_text() is no longer needed 2019-01-03 10:58:07 +09:00
Takeshi KOMIYA
76e9f57c2e Merge branch '1.8' 2019-01-02 16:16:25 +09:00
Takeshi KOMIYA
1b1ebd2c75 A happy new year! 2019-01-02 16:00:30 +09:00
Timotheus Kampik
edf9d210b6 #5660 adjust expected result to new classes
Also, fix formating glitch
2018-12-23 17:02:31 +01:00
Jon Dufresne
bade33c7e4 Remove unnecessary encoding cookie from Python source files
In Python 3, the default encoding of source files is utf-8. The encoding
cookie is now unnecessary and redundant so remove it. For more details,
see the docs:

https://docs.python.org/3/howto/unicode.html#the-string-type

> The default encoding for Python source code is UTF-8, so you can
> simply include a Unicode character in a string literal ...

Includes a fix for the flake8 header checks to stop expecting an
encoding cookie.
2018-12-16 12:22:12 -08:00
Takeshi KOMIYA
c6bd84a614 refactor: Remove u-prefix from strings 2018-12-16 21:28:51 +09:00
Takeshi KOMIYA
b56f4f9022 Remove print_function feature 2018-12-15 23:16:10 +09:00
jfbu
16f47cded9 Merge branch '1.8' 2018-11-06 18:30:21 +01:00
Takeshi KOMIYA
e3574a6f78 Fix #3002: i18n: multiple footnote_references referring same footnote causes duplicated node_ids 2018-11-01 00:54:25 +09:00
Takeshi KOMIYA
973c3ffa25
Merge branch 'master' into change_master_doc_to_index 2018-09-29 21:12:40 +09:00
Jon Dufresne
a3bc49dd64 Remove Python 2.6 compat shim for ElementTree.itertext 2018-09-22 10:32:28 -07:00
Takeshi KOMIYA
abcb5bd5ec The default setting for master_doc is changed to 'index' 2018-09-04 01:14:16 +09:00
Takeshi KOMIYA
328ff6eeae Fix i18n: warnings for translation catalogs have wrong line numbers 2018-08-22 21:01:50 +09:00
Takeshi KOMIYA
3e57ea0a52 Merge branch '1.7' 2018-07-17 00:37:40 +09:00
Takeshi KOMIYA
aad56c0361 Fix #3329: i18n: crashed by auto-symbol footnote references 2018-07-15 20:48:39 +09:00
Takeshi KOMIYA
bc19cf72c9 Merge branch '1.7' 2018-05-14 01:04:45 +09:00
Takeshi KOMIYA
e4410b6ab0
Merge branch '1.7' into 4913_literal_block_under_bullet_list 2018-05-12 22:35:55 +09:00
Takayuki SHIMIZUKAWA
79650f5827
fix #4938: i18n doesn't handle node.title correctly (#4939) 2018-05-11 20:51:07 +09:00
Takeshi KOMIYA
5c56c99dfd Fix #4913: i18n: literal blocks in bullet list are not translated 2018-05-07 22:25:42 +09:00
Takeshi KOMIYA
d01d494119 Deprecate env.update()!
To make BuildEnvironment simple, the responsibility of converting
source files to doctrees is moved to Builder class.
2018-02-24 13:06:46 +09:00
Takeshi KOMIYA
f7027049b1 Fix flake8 violations 2018-02-19 23:20:56 +09:00
Takeshi KOMIYA
dc3d03da1b test: Fix broken testcases 2018-01-15 01:01:13 +09:00
Takeshi KOMIYA
f1f6ca8cc9 Merge branch 'happy_new_year' into master 2018-01-01 01:09:17 +09:00
Takeshi KOMIYA
2426cedb8b A happy new year! 2018-01-01 01:06:58 +09:00
Takeshi KOMIYA
a9efb2517a Fix flake8 violations 2017-12-23 21:21:21 +09:00
Takeshi KOMIYA
2a2ed8915a diet test-root: Move .mo files to new testroot (for test_html_rebuild_mo) 2017-12-15 21:15:02 +09:00
Takeshi KOMIYA
47c869c89a Fix flake8 and style-check violations 2017-10-23 23:01:18 +09:00
cocoatomo
35d10033c2 Add (optional) u prefixes for Python 2.7 2017-10-08 01:55:53 +09:00
cocoatomo
73fd3f90bf Wrap the line too long 2017-10-08 01:29:07 +09:00
cocoatomo
ff88c8b730 Display reference texts of original and translated messages 2017-10-08 00:06:00 +09:00
cocoatomo
1f0c3ce875 Re-arrange WARNING messages about reference inconsistencies 2017-10-07 10:47:59 +09:00
Andy Neebel
f68c108f10 Mark tests as xfail/skip to allow successful run 2017-06-14 13:27:31 -05:00
shimizukawa
d497d74370 refs #3458: add sphinx.testing that are moved from /tests directory. 2017-05-14 20:47:15 +09:00
Takeshi KOMIYA
13acfd3ce1 Rename test-image-glob to test-images 2017-04-16 21:53:01 +09:00
Takeshi KOMIYA
8f9dd64992 Merge branch 'stable' 2017-03-26 11:52:15 +09:00
Takeshi KOMIYA
c57e47e042 Year++ 2017-03-26 11:49:34 +09:00
Takeshi KOMIYA
c7bec75bcd BuildEnvironment always own application object (after read phase) 2017-03-08 12:23:25 +09:00
Takeshi KOMIYA
1d0083edc5 Fix #3421: Could not translate a caption of tables 2017-02-26 13:47:53 +09:00
Takeshi KOMIYA
ece821e141 Merge branch 'master' into 3421_translate_table_caption 2017-02-26 13:43:36 +09:00
Takeshi KOMIYA
20510ef272 Merge branch 'stable' 2017-02-24 02:12:25 +09:00
Takeshi KOMIYA
13a48d330c Fix #3438: update timestamp certainly to ensure test condition 2017-02-24 02:12:09 +09:00
Takeshi KOMIYA
6b7dcf0889 Fix #3421: Could not translate a caption of tables 2017-02-15 18:08:54 +09:00
Takeshi KOMIYA
d33cf04979 Merge branch 'stable' 2017-01-29 18:05:17 +09:00
Takeshi KOMIYA
1a2488610d Fix #3370: the caption of code-block is not picked up for translation 2017-01-26 01:57:22 +09:00
Takeshi KOMIYA
cf2061dfad Fix flake8 violations 2017-01-26 01:13:17 +09:00
Takeshi KOMIYA
de3d03a7b5 Fix testcase 2017-01-10 01:06:57 +09:00
Takeshi KOMIYA
8cbe1efe8d Merge branch 'stable' 2017-01-10 01:04:21 +09:00
shimizukawa
b5530629a9 pytest: update by reviewing
* remove 'specific_srcdir' feature
* simplify 'shared_result' feature
* rename 'AppWrapper' into 'SphinxTestAppWrapperForSkipBuilding'
2017-01-09 17:41:47 +09:00
shimizukawa
561abdd164 pytest optimizatoin:
- remote using deprecated decorators
- remove gen_with_app
- remove yield testing
- remove pytest warnings
- refactoring
2017-01-08 15:14:38 +09:00
shimizukawa
4c22cd10ca Merge branch 'stable' 2017-01-07 02:14:29 +09:00
shimizukawa
baaef9146d pytest: remove deprecated with_app decorator functions 2017-01-06 01:14:47 +09:00
shimizukawa
380dd23d9f pytest: remove repr_as testing feature that avoids long annoying log for test generator feature on nose. In contrast, pytest does not produce such output. So repr_as is not needed anymore. refs #1785 2017-01-05 23:43:16 +09:00
shimizukawa
5b7d237db3 pytest migration 2017-01-04 00:59:30 +09:00
Takeshi KOMIYA
6d4e645409 Add sphinx.util.logging 2017-01-02 12:59:50 +09:00
Takeshi KOMIYA
9fc53cecf7 Reduce deprecation warnings (refs: #3192) 2016-12-15 17:15:49 +09:00
shimizukawa
5fc8d3db91 Fix: #2469: Ignore updates of catalog files for gettext builder. Thanks to Hiroshi Ohkubo. 2016-12-12 23:28:00 +09:00
Takeshi KOMIYA
0ee524e392 Merge branch 'stable' into 1.5-release 2016-11-23 13:22:38 +09:00
shimizukawa
8f79c11b04 #3093: fix test again 2016-11-20 18:35:12 +09:00
shimizukawa
6b0d3e7400 #3093: fix test again 2016-11-20 18:17:16 +09:00
Takeshi KOMIYA
4c3c128e9b Fix #3000: `option` directive generates invalid HTML anchors
fix
2016-10-07 12:11:28 +09:00
Takeshi KOMIYA
15518bad12 Fix could not translate the content of meta directive (ref: #1734) 2016-09-01 23:35:23 +09:00
Takeshi KOMIYA
9b00c31ee2 Fix #1734: Could not translate the caption of toctree directive 2016-09-01 17:58:24 +09:00
Takeshi KOMIYA
e96e627d59 Fix #2874: gettext builder could not extract all text under the `only` directives 2016-08-27 23:57:49 +09:00
Takeshi KOMIYA
372e83f0c7 Merge pull request #2853 from shibukawa/fix/genindex
Fix genindex.html to satisfy xhtml standard
2016-08-20 12:52:23 +09:00
Takeshi KOMIYA
a1d6be6a54 Fix #1797: text builder inserts blank line on top 2016-08-19 23:46:54 +09:00
Yoshiki Shibukawa
8e0bf12f5f Fix genindex.html to satisfy xhtml standard 2016-08-18 21:17:12 +09:00
Takeshi KOMIYA
80921b2ab8 Fix flake8 violation under tests/ 2016-06-12 00:02:11 +09:00
Takeshi KOMIYA
9df7783ba2 Fix #2395: Sphinx crashs if unicode character in image filename 2016-04-10 20:25:25 +09:00
Takeshi KOMIYA
f33e25dbad Fix broken merges 2016-03-03 23:14:16 +09:00
Takeshi KOMIYA
dda98c7d53 Merge branch 'useless-test-noise' 2016-03-03 23:01:34 +09:00
Takeshi KOMIYA
3f0843bca0 Add figure_language_filename to customize filename pattern for figure substitutions 2016-02-22 21:32:05 +09:00
Takeshi KOMIYA
1f5aa28db0 Fix #1921: Support figure substitutions by locale 2016-02-22 21:32:05 +09:00
Takeshi KOMIYA
5574aba60e Fix tests are broken with pygments-2.1 2016-01-18 12:38:02 +09:00
Takeshi KOMIYA
34cbf3bad7 Fix #2247: #2205 breaks make html for definition list with classifiers that contains regular-expression like string 2016-01-18 11:31:48 +09:00
Georg Brandl
46d7e8558e Obligatory copyright update. 2016-01-14 22:54:04 +01:00
Takeshi KOMIYA
053d7806fe Refactoring testcases to reduce ResourceWarning (refs: #1409) 2016-01-10 01:04:38 +09:00
shimizukawa
ac28f9b271 Fix #2198,#2205: `make gettext` generate broken msgid for definition lists. It's a regression by #1855. 2016-01-09 15:33:43 +09:00
Maximilian Köhl
65ad78daec [tests] beautify collapsed grouped field 2016-01-05 00:19:36 +09:00
shimizukawa
a3109f6976 Fixes #1983: i18n translation feature breaks references which uses section name. 2015-08-09 23:44:14 +09:00
shimizukawa
d3375761d2 Fixed #1855: make gettext generates broken po file for definition lists with classifier. 2015-07-25 17:41:07 +02:00
Takayuki Hirai
78000d2066 Fix #1780: Remove duplicated "class" and "exception" keywords from text builder 2015-04-28 22:17:09 +09:00
Robert Lehmann
657c53b0f5 Fixes #1785: Reduce output for test generators. 2015-03-20 22:26:32 +01:00
shimizukawa
87527b8558 fix too long line 2015-02-24 22:38:49 +09:00
shimizukawa
bb85c1c87f refs #1235: i18n: 'uri' and 'alt' attribute on 'image' and 'figure' nodes can be translated if gettext_additional_targets has 'image'. 2015-02-22 19:35:49 +09:00
shimizukawa
0ad1c154c0 refs #1235: i18n: 'doctest-block' and 'raw' node can be translated if gettext_additional_targets has that string. 2015-02-22 15:40:01 +09:00
shimizukawa
c53fa4b369 refs #1235: i18n: 'literal-block' node can be translated if 'literal-block' is set to gettext_additional_targets. 2015-02-22 13:51:02 +09:00
Georg Brandl
a23903d8d5 Merge branch 'stable' 2015-01-03 21:41:14 +01:00
Georg Brandl
567d52f199 all: update copyright 2015-01-03 21:36:32 +01:00
Georg Brandl
7bbaa4c73f Test suite fixes after env.update() change. 2014-09-22 15:08:15 +02:00
Georg Brandl
ac690b4b07 move new assertion helpers to util.py 2014-09-21 18:54:01 +02:00
Georg Brandl
fa91f19e55 Reimplement assert_in and assert_not_in, they are not in nose in Py2.6. 2014-09-21 18:48:21 +02:00
Georg Brandl
be72ed6dc7 Refactor/speed up test_intl by combining all tests with a certain builder into a generator. 2014-09-21 18:26:50 +02:00
Georg Brandl
d47a7587f9 Complete test suite overhaul.
* rename a few test modules to make the names more consistent

* do not copy/use Sphinx from build/ (unnecessary without 2to3)

* use a temporary dir for *all* test projects, the source tree
  will stay pristine that way  (default is tests/build)

* speed up tests by ~3x by splitting up test projects and avoiding
  rebuilds
2014-09-21 17:17:02 +02:00