Module ImportFrom alias ImportFrom alias alias alias ImportFrom alias ClassDef bases NameLoad body Expr Str Assign NameStore NameLoad Assign NameStore NameLoad Assign NameStore NameLoad Assign NameStore NameLoad Assign NameStore NameLoad FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr keyword Str keyword Str keyword Str keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad Assign NameStore BoolOpOr NameLoad AttributeLoad NameLoad attr If CompareIsNot NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad Return TupleLoad NameLoad Call AttributeLoad NameLoad attr NameLoad keyword NameLoad keyword NameLoad orelse Return TupleLoad NameLoad Call AttributeLoad NameLoad attr NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return IfExp UnaryOpNot AttributeLoad NameLoad attr NameLoad BinOpAdd NameLoad Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword ListLoad Str keyword Call AttributeLoad NameLoad attr Str keyword Dict NameLoad Str keyword NameLoad keyword NameLoad If AttributeLoad NameLoad attr body Expr Call NameLoad AttributeLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad attr ListLoad TupleLoad Str Str If AttributeLoad NameLoad attr body Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword Str keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword ListLoad Str Str keyword ListLoad keyword Call AttributeLoad NameLoad attr Str keyword Dict NameLoad Str keyword NameLoad keyword NameLoad If AttributeLoad NameLoad attr body Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword Str keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword ListLoad keyword ListLoad TupleLoad Str Str TupleLoad Str Str keyword Call AttributeLoad NameLoad attr Str keyword Dict NameLoad Str keyword NameLoad keyword NameLoad If AttributeLoad NameLoad attr body Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword Str keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword ListLoad keyword ListLoad keyword Call AttributeLoad NameLoad attr Str keyword Dict NameLoad Str keyword NameLoad keyword NameLoad If AttributeLoad NameLoad attr body Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword Str keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword ListLoad keyword ListLoad keyword Call AttributeLoad NameLoad attr Str keyword Dict NameLoad Str keyword NameLoad keyword NameLoad If AttributeLoad NameLoad attr body Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword Str keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword ListLoad keyword ListLoad keyword Call AttributeLoad NameLoad attr Str keyword Dict keyword NameLoad keyword NameLoad If AttributeLoad NameLoad attr body Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword Str keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword ListLoad keyword ListLoad keyword Call AttributeLoad NameLoad attr Str keyword Dict Num Num Str Str keyword NameLoad keyword NameLoad If AttributeLoad NameLoad attr body Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword Str keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword ListLoad keyword ListLoad keyword Call AttributeLoad NameLoad attr Str keyword Dict Num Str keyword NameLoad keyword NameLoad If AttributeLoad NameLoad attr body Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword Str keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword ListLoad keyword ListLoad keyword Call AttributeLoad NameLoad attr Str keyword Dict NameLoad Str keyword NameLoad keyword NameLoad If AttributeLoad NameLoad attr body Expr Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad keyword Str decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body With Call NameLoad NameLoad NameStore body Assign NameStore Call AttributeLoad NameLoad attr If NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad FunctionDef arguments args NameParam defaults body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Num Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad Str Assign AttributeStore NameLoad attr NameLoad decorator_list Expr Call BoolOpOr NameLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad FunctionDef arguments args NameParam defaults body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Num Assign AttributeStore NameLoad attr Dict decorator_list Expr Call BoolOpOr NameLoad NameLoad NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Num Assign SubscriptStore AttributeLoad NameLoad attr Index Num Str Assign SubscriptStore AttributeLoad NameLoad attr Index Num Str Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body Expr Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Num Assign SubscriptStore AttributeLoad NameLoad attr Index Num Str Delete SubscriptDel AttributeLoad NameLoad attr Index Num Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Assign AttributeStore SubscriptLoad AttributeLoad NameLoad attr Index Num attr NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Expr Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Assign NameStore Call NameLoad AttributeLoad NameLoad attr keyword Str Assign AttributeStore NameLoad attr Dict NameLoad Str Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Expr Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Assign NameStore Call NameLoad AttributeLoad NameLoad attr keyword Str Assign AttributeStore NameLoad attr Dict NameLoad Str Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad body Expr Str Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list decorator_list
N/A django_nose.tools assert_equal pontoon.base.tests assert_attributes_equal create_tempfile LocaleFactory pontoon.base.utils match_attr FormatTestsMixin N/A object N/A N/A 
    Mixin for tests and methods that are common to all supported
    formats.

    Each format we support should have a test class that subclasses this
    class and overrides the tests for features that it supports. If a
    format doesn't support a particular feature, don't override the
    test method for that feature and it won't be run.
     N/A maxDiff None N/A parse None N/A supports_keys False N/A supports_source False N/A supports_source_string False setUp N/A N/A self N/A N/A N/A N/A N/A N/A super FormatTestsMixin self setUp N/A N/A self locale N/A N/A LocaleFactory create code test-locale name Test Locale plural_rule (n != 1) cldr_plurals 1,5 N/A parse_string N/A N/A self string source_string locale N/A None None N/A N/A path N/A create_tempfile string N/A locale N/A locale N/A self locale N/A N/A source_string None N/A N/A source_path N/A create_tempfile source_string N/A N/A path N/A N/A self parse path source_path source_path locale locale N/A N/A N/A path N/A N/A self parse path locale locale N/A key N/A N/A self source_string N/A N/A N/A 
        Return the expected key for an entity with the given source
        string based on whether the format we're testing supports unique
        keys or not.
         N/A N/A N/A N/A self supports_keys source_string N/A source_string  Key N/A run_parse_basic N/A N/A self input_string translation_index N/A N/A N/A Basic translation with a comment and source. N/A N/A path resource N/A N/A self parse_string input_string N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index comments N/A Sample comment key N/A N/A self key Source String strings N/A None Translated String fuzzy False order translation_index N/A N/A self supports_source N/A N/A N/A assert_equal N/A N/A N/A resource translations N/A translation_index source N/A N/A file.py 1 N/A N/A self supports_source_string N/A N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index source_string Source String source_string_plural N/A run_parse_multiple_comments N/A N/A self input_string translation_index N/A N/A N/A N/A path resource N/A N/A self parse_string input_string N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index comments N/A First comment Second comment source N/A key N/A N/A self key Multiple Comments strings N/A None Translated Multiple Comments fuzzy False order translation_index N/A N/A self supports_source_string N/A N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index source_string Multiple Comments source_string_plural N/A run_parse_multiple_sources N/A N/A self input_string translation_index N/A N/A N/A N/A path resource N/A N/A self parse_string input_string N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index comments N/A source N/A N/A file.py 2 N/A file.py 3 key N/A N/A self key Multiple Sources strings N/A None Translated Multiple Sources fuzzy False order translation_index N/A N/A self supports_source_string N/A N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index source_string Multiple Sources source_string_plural N/A run_parse_fuzzy N/A N/A self input_string translation_index N/A N/A N/A N/A path resource N/A N/A self parse_string input_string N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index comments N/A source N/A key N/A N/A self key Fuzzy strings N/A None Translated Fuzzy fuzzy True order translation_index N/A N/A self supports_source_string N/A N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index source_string Fuzzy source_string_plural N/A run_parse_no_comments_no_sources N/A N/A self input_string translation_index N/A N/A N/A N/A path resource N/A N/A self parse_string input_string N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index comments N/A source N/A key N/A N/A self key No Comments or Sources strings N/A None Translated No Comments or Sources fuzzy False order translation_index N/A N/A self supports_source_string N/A N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index source_string No Comments or Sources source_string_plural N/A run_parse_missing_traslation N/A N/A self input_string translation_index N/A N/A N/A N/A path resource N/A N/A self parse_string input_string N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index comments N/A source N/A key N/A N/A self key Missing Translation strings N/A fuzzy False order translation_index N/A N/A self supports_source_string N/A N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index source_string Missing Translation source_string_plural N/A run_parse_plural_translation N/A N/A self input_string translation_index N/A N/A N/A N/A path resource N/A N/A self parse_string input_string N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index comments N/A source N/A key N/A N/A self key Plural %(count)s string strings N/A 0 1 Translated Plural %(count)s string Translated Plural %(count)s strings fuzzy False order translation_index N/A N/A self supports_source_string N/A N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index source_string Plural %(count)s string source_string_plural Plural %(count)s strings N/A run_parse_plural_translation_missing N/A N/A self input_string translation_index N/A N/A N/A N/A path resource N/A N/A self parse_string input_string N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index comments N/A source N/A key N/A N/A self key Plural %(count)s string with missing translations strings N/A 1 Translated Plural %(count)s strings with missing translations fuzzy False order translation_index N/A N/A self supports_source_string N/A N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index source_string Plural %(count)s string with missing translations source_string_plural Plural %(count)s strings with missing translations N/A run_parse_empty_translation N/A N/A self input_string translation_index N/A N/A N/A Test that empty translations are parsed properly. N/A N/A path resource N/A N/A self parse_string input_string N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index comments N/A source N/A key N/A N/A self key Empty Translation strings N/A None fuzzy False order translation_index N/A N/A self supports_source_string N/A N/A N/A assert_attributes_equal N/A N/A resource translations N/A translation_index source_string Empty Translation N/A assert_file_content N/A N/A self file_path expected_content strip N/A True N/A N/A N/A open file_path f N/A N/A actual_content N/A N/A f read N/A strip N/A N/A actual_content N/A N/A actual_content strip N/A expected_content N/A N/A expected_content strip N/A N/A N/A self assertMultiLineEqual actual_content expected_content N/A run_save_basic N/A N/A self input_string expected_string source_string resource_cb N/A None None N/A N/A 
        Test saving changes to an entity with a single translation.
         N/A N/A path resource N/A N/A self parse_string input_string source_string source_string test_default N/A N/A res N/A N/A N/A translation N/A N/A res translations N/A 0 N/A N/A N/A translation strings N/A None New Translated String N/A N/A translation fuzzy True N/A N/A N/A N/A resource_cb test_default resource N/A N/A N/A resource save N/A self locale N/A N/A N/A self assert_file_content path expected_string N/A run_save_remove N/A N/A self input_string expected_string source_string remove_cb N/A None None N/A N/A Test saving a removed entity with a single translation. N/A N/A path resource N/A N/A self parse_string input_string source_string source_string default_remove N/A N/A res N/A N/A N/A translation N/A N/A res translations N/A 0 N/A N/A translation strings N/A N/A N/A N/A N/A remove_cb default_remove resource N/A N/A N/A resource save N/A self locale N/A N/A N/A self assert_file_content path expected_string N/A run_save_plural N/A N/A self input_string expected_string source_string N/A None N/A N/A N/A path resource N/A N/A self parse_string input_string source_string source_string N/A translation N/A N/A resource translations N/A 0 N/A N/A N/A translation strings N/A 0 New Plural N/A N/A N/A translation strings N/A 1 New Plurals N/A N/A N/A resource save N/A self locale N/A N/A N/A self assert_file_content path expected_string N/A run_save_plural_remove N/A N/A self input_string expected_string source_string N/A None N/A N/A 
        Any missing plurals should be set to an empty string in the
        pofile.
         N/A N/A path resource N/A N/A self parse_string input_string source_string source_string N/A translation N/A N/A resource translations N/A 0 N/A N/A N/A translation strings N/A 0 New Plural N/A N/A N/A translation strings N/A 1 N/A N/A N/A resource save N/A self locale N/A N/A N/A self assert_file_content path expected_string N/A run_save_remove_fuzzy N/A N/A self input_string expected_string source_string N/A None N/A N/A N/A path resource N/A N/A self parse_string input_string source_string source_string N/A N/A N/A N/A resource translations N/A 0 fuzzy False N/A N/A N/A resource save N/A self locale N/A N/A N/A self assert_file_content path expected_string N/A run_save_translation_missing N/A N/A self source_string input_string expected_string N/A N/A N/A 
        If the source resource has a string but the translated resource
        doesn't, the returned resource should have an empty translation
        that can be modified and saved.

        Source Example:
            String=Source String
            MissingString=Missing Source String

        Input Example:
            String=Translated String

        Expected Example:
            String=Translated String
            MissingString=Translated Missing String
         N/A N/A path resource N/A N/A self parse_string input_string source_string source_string N/A missing_translation N/A match_attr N/A resource translations key MissingString N/A N/A missing_translation strings N/A None Translated Missing String N/A N/A N/A resource save N/A self locale N/A N/A N/A self assert_file_content path expected_string N/A run_save_translation_identical N/A N/A self source_string input_string expected_string N/A N/A N/A 
        If the updated translation is identical to the source
        translation, keep it.

        Source Example:
            String=Source String

        Input Example:
            String=Translated String

        Expected Example:
            String=Source String
         N/A N/A path resource N/A N/A self parse_string input_string source_string source_string N/A translation N/A match_attr N/A resource translations key String N/A N/A translation strings N/A None Source String N/A N/A N/A resource save N/A self locale N/A N/A N/A self assert_file_content path expected_string N/A run_save_no_changes N/A N/A self input_string expected_string source_string N/A None N/A N/A Test what happens when no changes are made. N/A N/A path resource N/A N/A self parse_string input_string source_string source_string N/A N/A N/A resource save N/A self locale N/A N/A N/A self assert_file_content path expected_string N/A N/A