phrase 2.12.0 → 2.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +21 -0
  3. data/README.md +25 -13
  4. data/docs/Comment.md +5 -1
  5. data/docs/CommentReaction.md +27 -0
  6. data/docs/CommentReactionsApi.md +289 -0
  7. data/docs/CommentRepliesApi.md +427 -0
  8. data/docs/CommentsApi.md +5 -1
  9. data/docs/DistributionCreateParameters.md +1 -1
  10. data/docs/GitlabSyncHistory.md +2 -2
  11. data/docs/GitlabSyncHistoryErrors.md +19 -0
  12. data/docs/JobLocaleUpdateParameters.md +1 -1
  13. data/docs/JobLocalesApi.md +20 -20
  14. data/docs/JobLocalesCreateParameters.md +1 -1
  15. data/docs/LocalesApi.md +2 -2
  16. data/docs/SpacesApi.md +9 -9
  17. data/docs/TeamsApi.md +6 -6
  18. data/docs/UploadCreateParameters.md +1 -1
  19. data/docs/UploadsApi.md +2 -2
  20. data/lib/phrase/api/comment_reactions_api.rb +353 -0
  21. data/lib/phrase/api/comment_replies_api.rb +523 -0
  22. data/lib/phrase/api/comments_api.rb +6 -0
  23. data/lib/phrase/api/job_locales_api.rb +20 -20
  24. data/lib/phrase/api/locales_api.rb +2 -2
  25. data/lib/phrase/api/spaces_api.rb +6 -6
  26. data/lib/phrase/api/teams_api.rb +4 -4
  27. data/lib/phrase/api/uploads_api.rb +2 -2
  28. data/lib/phrase/models/comment.rb +24 -4
  29. data/lib/phrase/models/comment_reaction.rb +239 -0
  30. data/lib/phrase/models/distribution_create_parameters.rb +1 -1
  31. data/lib/phrase/models/gitlab_sync_history.rb +2 -2
  32. data/lib/phrase/models/gitlab_sync_history_errors.rb +203 -0
  33. data/lib/phrase/models/job_locale_update_parameters.rb +1 -1
  34. data/lib/phrase/models/job_locales_create_parameters.rb +1 -1
  35. data/lib/phrase/models/upload_create_parameters.rb +1 -1
  36. data/lib/phrase/version.rb +1 -1
  37. data/lib/phrase.rb +4 -0
  38. data/spec/api/comment_reactions_api_spec.rb +92 -0
  39. data/spec/api/comment_replies_api_spec.rb +126 -0
  40. data/spec/api/comments_api_spec.rb +2 -0
  41. data/spec/api/job_locales_api_spec.rb +10 -10
  42. data/spec/api/locales_api_spec.rb +1 -1
  43. data/spec/api/spaces_api_spec.rb +3 -3
  44. data/spec/api/teams_api_spec.rb +2 -2
  45. data/spec/api/uploads_api_spec.rb +1 -1
  46. data/spec/models/comment_reaction_spec.rb +59 -0
  47. data/spec/models/comment_spec.rb +12 -0
  48. data/spec/models/gitlab_sync_history_errors_spec.rb +35 -0
  49. metadata +228 -211
data/lib/phrase.rb CHANGED
@@ -34,6 +34,7 @@ require 'phrase/models/branch_update_parameters'
34
34
  require 'phrase/models/comment'
35
35
  require 'phrase/models/comment_create_parameters'
36
36
  require 'phrase/models/comment_mark_read_parameters'
37
+ require 'phrase/models/comment_reaction'
37
38
  require 'phrase/models/comment_update_parameters'
38
39
  require 'phrase/models/current_user'
39
40
  require 'phrase/models/distribution'
@@ -48,6 +49,7 @@ require 'phrase/models/gitlab_sync'
48
49
  require 'phrase/models/gitlab_sync_export'
49
50
  require 'phrase/models/gitlab_sync_export_parameters'
50
51
  require 'phrase/models/gitlab_sync_history'
52
+ require 'phrase/models/gitlab_sync_history_errors'
51
53
  require 'phrase/models/gitlab_sync_import_parameters'
52
54
  require 'phrase/models/glossary'
53
55
  require 'phrase/models/glossary_create_parameters'
@@ -217,6 +219,8 @@ require 'phrase/api/authorizations_api'
217
219
  require 'phrase/api/bitbucket_sync_api'
218
220
  require 'phrase/api/blacklisted_keys_api'
219
221
  require 'phrase/api/branches_api'
222
+ require 'phrase/api/comment_reactions_api'
223
+ require 'phrase/api/comment_replies_api'
220
224
  require 'phrase/api/comments_api'
221
225
  require 'phrase/api/distributions_api'
222
226
  require 'phrase/api/documents_api'
@@ -0,0 +1,92 @@
1
+ require 'spec_helper'
2
+ require 'json'
3
+
4
+ # Unit tests for Phrase::CommentReactionsApi
5
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
6
+ # Please update as you see appropriate
7
+ describe 'CommentReactionsApi' do
8
+ before do
9
+ # run before each test
10
+ @api_instance = Phrase::CommentReactionsApi.new
11
+ end
12
+
13
+ after do
14
+ # run after each test
15
+ end
16
+
17
+ describe 'test an instance of CommentReactionsApi' do
18
+ it 'should create an instance of CommentReactionsApi' do
19
+ expect(@api_instance).to be_instance_of(Phrase::CommentReactionsApi)
20
+ end
21
+ end
22
+
23
+ # unit tests for reaction_create
24
+ # Create a reaction
25
+ # Create a new reaction for a comment.
26
+ # @param project_id Project ID
27
+ # @param key_id Translation Key ID
28
+ # @param comment_id Comment ID
29
+ # @param [Hash] opts the optional parameters
30
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
31
+ # @option opts [String] :branch specify the branch to use
32
+ # @option opts [String] :emoji specify the emoji for the reaction
33
+ # @return [CommentReaction]
34
+ describe 'reaction_create test' do
35
+ it 'should work' do
36
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
37
+ end
38
+ end
39
+
40
+ # unit tests for reaction_delete
41
+ # Delete a reaction
42
+ # Delete an existing reaction.
43
+ # @param project_id Project ID
44
+ # @param key_id Translation Key ID
45
+ # @param comment_id Comment ID
46
+ # @param id ID
47
+ # @param [Hash] opts the optional parameters
48
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
49
+ # @option opts [String] :branch specify the branch to use
50
+ # @return [nil]
51
+ describe 'reaction_delete test' do
52
+ it 'should work' do
53
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
54
+ end
55
+ end
56
+
57
+ # unit tests for reaction_show
58
+ # Get a single reaction
59
+ # Get details on a single reaction.
60
+ # @param project_id Project ID
61
+ # @param key_id Translation Key ID
62
+ # @param comment_id Comment ID
63
+ # @param id ID
64
+ # @param [Hash] opts the optional parameters
65
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
66
+ # @option opts [String] :branch specify the branch to use
67
+ # @return [CommentReaction]
68
+ describe 'reaction_show test' do
69
+ it 'should work' do
70
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
71
+ end
72
+ end
73
+
74
+ # unit tests for reactions_list
75
+ # List reactions
76
+ # List all reactions for a comment.
77
+ # @param project_id Project ID
78
+ # @param key_id Translation Key ID
79
+ # @param comment_id Comment ID
80
+ # @param [Hash] opts the optional parameters
81
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
82
+ # @option opts [Integer] :page Page number
83
+ # @option opts [Integer] :per_page Limit on the number of objects to be returned, between 1 and 100. 25 by default
84
+ # @option opts [String] :branch specify the branch to use
85
+ # @return [Array<CommentReaction>]
86
+ describe 'reactions_list test' do
87
+ it 'should work' do
88
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
89
+ end
90
+ end
91
+
92
+ end
@@ -0,0 +1,126 @@
1
+ require 'spec_helper'
2
+ require 'json'
3
+
4
+ # Unit tests for Phrase::CommentRepliesApi
5
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
6
+ # Please update as you see appropriate
7
+ describe 'CommentRepliesApi' do
8
+ before do
9
+ # run before each test
10
+ @api_instance = Phrase::CommentRepliesApi.new
11
+ end
12
+
13
+ after do
14
+ # run after each test
15
+ end
16
+
17
+ describe 'test an instance of CommentRepliesApi' do
18
+ it 'should create an instance of CommentRepliesApi' do
19
+ expect(@api_instance).to be_instance_of(Phrase::CommentRepliesApi)
20
+ end
21
+ end
22
+
23
+ # unit tests for replies_list
24
+ # List replies
25
+ # List all replies for a comment.
26
+ # @param project_id Project ID
27
+ # @param key_id Translation Key ID
28
+ # @param comment_id Comment ID
29
+ # @param [Hash] opts the optional parameters
30
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
31
+ # @option opts [Integer] :page Page number
32
+ # @option opts [Integer] :per_page Limit on the number of objects to be returned, between 1 and 100. 25 by default
33
+ # @option opts [String] :branch specify the branch to use
34
+ # @return [Array<Comment>]
35
+ describe 'replies_list test' do
36
+ it 'should work' do
37
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
38
+ end
39
+ end
40
+
41
+ # unit tests for reply_create
42
+ # Create a reply
43
+ # Create a new reply for a comment.
44
+ # @param project_id Project ID
45
+ # @param key_id Translation Key ID
46
+ # @param comment_id Comment ID
47
+ # @param [Hash] opts the optional parameters
48
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
49
+ # @option opts [String] :branch specify the branch to use
50
+ # @option opts [String] :message specify the message for the comment
51
+ # @return [Comment]
52
+ describe 'reply_create test' do
53
+ it 'should work' do
54
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
55
+ end
56
+ end
57
+
58
+ # unit tests for reply_delete
59
+ # Delete a reply
60
+ # Delete an existing reply.
61
+ # @param project_id Project ID
62
+ # @param key_id Translation Key ID
63
+ # @param comment_id Comment ID
64
+ # @param id ID
65
+ # @param [Hash] opts the optional parameters
66
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
67
+ # @option opts [String] :branch specify the branch to use
68
+ # @return [nil]
69
+ describe 'reply_delete test' do
70
+ it 'should work' do
71
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
72
+ end
73
+ end
74
+
75
+ # unit tests for reply_mark_as_read
76
+ # Mark a reply as read
77
+ # Mark a reply as read.
78
+ # @param project_id Project ID
79
+ # @param key_id Translation Key ID
80
+ # @param comment_id Comment ID
81
+ # @param id ID
82
+ # @param [Hash] opts the optional parameters
83
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
84
+ # @option opts [String] :branch specify the branch to use
85
+ # @return [nil]
86
+ describe 'reply_mark_as_read test' do
87
+ it 'should work' do
88
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
89
+ end
90
+ end
91
+
92
+ # unit tests for reply_mark_as_unread
93
+ # Mark a reply as unread
94
+ # Mark a reply as unread.
95
+ # @param project_id Project ID
96
+ # @param key_id Translation Key ID
97
+ # @param comment_id Comment ID
98
+ # @param id ID
99
+ # @param [Hash] opts the optional parameters
100
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
101
+ # @option opts [String] :branch specify the branch to use
102
+ # @return [nil]
103
+ describe 'reply_mark_as_unread test' do
104
+ it 'should work' do
105
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
106
+ end
107
+ end
108
+
109
+ # unit tests for reply_show
110
+ # Get a single reply
111
+ # Get details on a single reply.
112
+ # @param project_id Project ID
113
+ # @param key_id Translation Key ID
114
+ # @param comment_id Comment ID
115
+ # @param id ID
116
+ # @param [Hash] opts the optional parameters
117
+ # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
118
+ # @option opts [String] :branch specify the branch to use
119
+ # @return [Comment]
120
+ describe 'reply_show test' do
121
+ it 'should work' do
122
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
123
+ end
124
+ end
125
+
126
+ end
@@ -28,6 +28,8 @@ describe 'CommentsApi' do
28
28
  # @param comment_create_parameters
29
29
  # @param [Hash] opts the optional parameters
30
30
  # @option opts [String] :x_phrase_app_otp Two-Factor-Authentication token (optional)
31
+ # @option opts [String] :message specify the message for the comment
32
+ # @option opts [Array<String>] :locale_ids specify the locales for the comment
31
33
  # @return [Comment]
32
34
  describe 'comment_create test' do
33
35
  it 'should work' do
@@ -53,8 +53,8 @@ describe 'JobLocalesApi' do
53
53
  end
54
54
 
55
55
  # unit tests for job_locale_delete
56
- # Delete a job locale
57
- # Delete an existing job locale.
56
+ # Remove a target locale from a job
57
+ # Removes a target locale from a job.
58
58
  # @param project_id Project ID
59
59
  # @param job_id Job ID
60
60
  # @param id ID
@@ -85,8 +85,8 @@ describe 'JobLocalesApi' do
85
85
  end
86
86
 
87
87
  # unit tests for job_locale_show
88
- # Get a single job locale
89
- # Get a single job locale for a given job.
88
+ # Show single job target locale
89
+ # Get a single target locale for a given job.
90
90
  # @param project_id Project ID
91
91
  # @param job_id Job ID
92
92
  # @param id ID
@@ -101,8 +101,8 @@ describe 'JobLocalesApi' do
101
101
  end
102
102
 
103
103
  # unit tests for job_locale_update
104
- # Update a job locale
105
- # Update an existing job locale.
104
+ # Update a job target locale
105
+ # Update an existing job target locale.
106
106
  # @param project_id Project ID
107
107
  # @param job_id Job ID
108
108
  # @param id ID
@@ -117,8 +117,8 @@ describe 'JobLocalesApi' do
117
117
  end
118
118
 
119
119
  # unit tests for job_locales_create
120
- # Create a job locale
121
- # Create a new job locale.
120
+ # Add a target locale to a job
121
+ # Adds a target locale to a job.
122
122
  # @param project_id Project ID
123
123
  # @param job_id Job ID
124
124
  # @param job_locales_create_parameters
@@ -132,8 +132,8 @@ describe 'JobLocalesApi' do
132
132
  end
133
133
 
134
134
  # unit tests for job_locales_list
135
- # List job locales
136
- # List all job locales for a given job.
135
+ # List job target locales
136
+ # List all target locales for a given job.
137
137
  # @param project_id Project ID
138
138
  # @param job_id Job ID
139
139
  # @param [Hash] opts the optional parameters
@@ -86,7 +86,7 @@ describe 'LocalesApi' do
86
86
  # @option opts [String] :encoding Enforces a specific encoding on the file contents. Valid options are \&quot;UTF-8\&quot;, \&quot;UTF-16\&quot; and \&quot;ISO-8859-1\&quot;.
87
87
  # @option opts [Boolean] :skip_unverified_translations Indicates whether the locale file should skip all unverified translations. This parameter is deprecated and should be replaced with &lt;code&gt;include_unverified_translations&lt;/code&gt;.
88
88
  # @option opts [Boolean] :include_unverified_translations if set to false unverified translations are excluded
89
- # @option opts [Boolean] :use_last_reviewed_version If set to true the last reviewed version of a translation is used. This is only available if the review workflow (currently in beta) is enabled for the project.
89
+ # @option opts [Boolean] :use_last_reviewed_version If set to true the last reviewed version of a translation is used. This is only available if the review workflow is enabled for the project.
90
90
  # @option opts [String] :fallback_locale_id If a key has no translation in the locale being downloaded the translation in the fallback locale will be used. Provide the public ID of the locale that should be used as the fallback. Requires include_empty_translations to be set to &lt;code&gt;true&lt;/code&gt;.
91
91
  # @option opts [String] :source_locale_id Provides the source language of a corresponding job as the source language of the generated locale file. This parameter will be ignored unless used in combination with a &lt;code&gt;tag&lt;/code&gt; parameter indicating a specific job.
92
92
  # @return [File]
@@ -93,7 +93,7 @@ describe 'SpacesApi' do
93
93
  end
94
94
 
95
95
  # unit tests for spaces_projects_create
96
- # Add Project
96
+ # Add Project to Space
97
97
  # Adds an existing project to the space.
98
98
  # @param account_id Account ID
99
99
  # @param space_id Space ID
@@ -108,7 +108,7 @@ describe 'SpacesApi' do
108
108
  end
109
109
 
110
110
  # unit tests for spaces_projects_delete
111
- # Remove Project
111
+ # Remove Project from Space
112
112
  # Removes a specified project from the specified space.
113
113
  # @param account_id Account ID
114
114
  # @param space_id Space ID
@@ -123,7 +123,7 @@ describe 'SpacesApi' do
123
123
  end
124
124
 
125
125
  # unit tests for spaces_projects_list
126
- # List Projects
126
+ # List Projects in Space
127
127
  # List all projects for the specified Space.
128
128
  # @param account_id Account ID
129
129
  # @param space_id Space ID
@@ -93,7 +93,7 @@ describe 'TeamsApi' do
93
93
  end
94
94
 
95
95
  # unit tests for teams_projects_create
96
- # Add Project
96
+ # Add Project to Team
97
97
  # Adds an existing project to the team.
98
98
  # @param account_id Account ID
99
99
  # @param team_id Team ID
@@ -108,7 +108,7 @@ describe 'TeamsApi' do
108
108
  end
109
109
 
110
110
  # unit tests for teams_projects_delete
111
- # Remove Project
111
+ # Remove Project from Team
112
112
  # Removes a specified project from the specified team.
113
113
  # @param account_id Account ID
114
114
  # @param team_id Team ID
@@ -40,7 +40,7 @@ describe 'UploadsApi' do
40
40
  # @option opts [Object] :locale_mapping Optional, format specific mapping between locale names and the columns the translations to those locales are contained in.
41
41
  # @option opts [Object] :format_options Additional options available for specific formats. See our format guide for complete list.
42
42
  # @option opts [Boolean] :autotranslate If set, translations for the uploaded language will be fetched automatically.
43
- # @option opts [Boolean] :mark_reviewed Indicated whether the imported translations should be marked as reviewed. This setting is available if the review workflow (currently beta) is enabled for the project.
43
+ # @option opts [Boolean] :mark_reviewed Indicated whether the imported translations should be marked as reviewed. This setting is available if the review workflow is enabled for the project.
44
44
  # @return [Upload]
45
45
  describe 'upload_create test' do
46
46
  it 'should work' do
@@ -0,0 +1,59 @@
1
+ require 'spec_helper'
2
+ require 'json'
3
+ require 'date'
4
+
5
+ # Unit tests for Phrase::CommentReaction
6
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
7
+ # Please update as you see appropriate
8
+ describe 'CommentReaction' do
9
+ before do
10
+ # run before each test
11
+ @instance = Phrase::CommentReaction.new
12
+ end
13
+
14
+ after do
15
+ # run after each test
16
+ end
17
+
18
+ describe 'test an instance of CommentReaction' do
19
+ it 'should create an instance of CommentReaction' do
20
+ expect(@instance).to be_instance_of(Phrase::CommentReaction)
21
+ end
22
+ end
23
+ describe 'test attribute "id"' do
24
+ it 'should work' do
25
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
26
+ end
27
+ end
28
+
29
+ describe 'test attribute "emoji"' do
30
+ it 'should work' do
31
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
32
+ end
33
+ end
34
+
35
+ describe 'test attribute "created_at"' do
36
+ it 'should work' do
37
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
38
+ end
39
+ end
40
+
41
+ describe 'test attribute "updated_at"' do
42
+ it 'should work' do
43
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
44
+ end
45
+ end
46
+
47
+ describe 'test attribute "comment"' do
48
+ it 'should work' do
49
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
50
+ end
51
+ end
52
+
53
+ describe 'test attribute "user"' do
54
+ it 'should work' do
55
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
56
+ end
57
+ end
58
+
59
+ end
@@ -32,6 +32,12 @@ describe 'Comment' do
32
32
  end
33
33
  end
34
34
 
35
+ describe 'test attribute "has_replies"' do
36
+ it 'should work' do
37
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
38
+ end
39
+ end
40
+
35
41
  describe 'test attribute "user"' do
36
42
  it 'should work' do
37
43
  # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
@@ -56,4 +62,10 @@ describe 'Comment' do
56
62
  end
57
63
  end
58
64
 
65
+ describe 'test attribute "locales"' do
66
+ it 'should work' do
67
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
68
+ end
69
+ end
70
+
59
71
  end
@@ -0,0 +1,35 @@
1
+ require 'spec_helper'
2
+ require 'json'
3
+ require 'date'
4
+
5
+ # Unit tests for Phrase::GitlabSyncHistoryErrors
6
+ # Automatically generated by openapi-generator (https://openapi-generator.tech)
7
+ # Please update as you see appropriate
8
+ describe 'GitlabSyncHistoryErrors' do
9
+ before do
10
+ # run before each test
11
+ @instance = Phrase::GitlabSyncHistoryErrors.new
12
+ end
13
+
14
+ after do
15
+ # run after each test
16
+ end
17
+
18
+ describe 'test an instance of GitlabSyncHistoryErrors' do
19
+ it 'should create an instance of GitlabSyncHistoryErrors' do
20
+ expect(@instance).to be_instance_of(Phrase::GitlabSyncHistoryErrors)
21
+ end
22
+ end
23
+ describe 'test attribute "error"' do
24
+ it 'should work' do
25
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
26
+ end
27
+ end
28
+
29
+ describe 'test attribute "message"' do
30
+ it 'should work' do
31
+ # assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
32
+ end
33
+ end
34
+
35
+ end