Skip to content

Commit

Permalink
Deploying from phrase/openapi@7332a84f
Browse files Browse the repository at this point in the history
  • Loading branch information
Phrase committed Dec 13, 2023
1 parent 2914667 commit 0d0e49a
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 6 deletions.
2 changes: 1 addition & 1 deletion docs/KeyCreateParameters.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ instance = Phrase::KeyCreateParameters.new(branch: my-feature-branch,
data_type: number,
tags: awesome-feature,needs-proofreading,
max_characters_allowed: 140,
screenshot: [B@2488a11,
screenshot: [B@476fc8a1,
remove_screenshot: null,
unformatted: null,
default_translation_content: Default translation content,
Expand Down
2 changes: 1 addition & 1 deletion docs/KeyUpdateParameters.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ instance = Phrase::KeyUpdateParameters.new(branch: my-feature-branch,
data_type: number,
tags: awesome-feature,needs-proofreading,
max_characters_allowed: 140,
screenshot: [B@8936d23,
screenshot: [B@ddf8b1d,
remove_screenshot: null,
unformatted: null,
xml_space_preserve: null,
Expand Down
2 changes: 1 addition & 1 deletion docs/ProjectCreateParameters.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ instance = Phrase::ProjectCreateParameters.new(name: My Android Project,
main_format: yml,
media: Python,
shares_translation_memory: true,
project_image: [B@23ccdee9,
project_image: [B@5af2bc6,
remove_project_image: null,
account_id: abcd1234,
point_of_contact: abcd1234,
Expand Down
2 changes: 1 addition & 1 deletion docs/ProjectUpdateParameters.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ instance = Phrase::ProjectUpdateParameters.new(account_id: abcd1234,
main_format: yml,
media: Python,
shares_translation_memory: true,
project_image: [B@34a7decd,
project_image: [B@43f13160,
remove_project_image: false,
workflow: review,
machine_translation_enabled: true,
Expand Down
2 changes: 1 addition & 1 deletion docs/ScreenshotUpdateParameters.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ require 'Phrase'
instance = Phrase::ScreenshotUpdateParameters.new(branch: my-feature-branch,
name: A screenshot name,
description: A screenshot description,
filename: [B@47362f88)
filename: [B@3be22500)
```


2 changes: 2 additions & 0 deletions docs/Upload.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Name | Type | Description | Notes
**format** | **String** | | [optional]
**state** | **String** | | [optional]
**tag** | **String** | | [optional]
**url** | **String** | The URL to the upload in Phrase Strings app. | [optional]
**summary** | [**UploadSummary**](UploadSummary.md) | | [optional]
**created_at** | **Time** | | [optional]
**updated_at** | **Time** | | [optional]
Expand All @@ -23,6 +24,7 @@ instance = Phrase::Upload.new(id: null,
format: null,
state: null,
tag: null,
url: null,
summary: null,
created_at: null,
updated_at: null)
Expand Down
12 changes: 11 additions & 1 deletion lib/phrase/models/upload.rb
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ class Upload

attr_accessor :tag

# The URL to the upload in Phrase Strings app.
attr_accessor :url

attr_accessor :summary

attr_accessor :created_at
Expand All @@ -26,6 +29,7 @@ def self.attribute_map
:'format' => :'format',
:'state' => :'state',
:'tag' => :'tag',
:'url' => :'url',
:'summary' => :'summary',
:'created_at' => :'created_at',
:'updated_at' => :'updated_at'
Expand All @@ -40,6 +44,7 @@ def self.openapi_types
:'format' => :'String',
:'state' => :'String',
:'tag' => :'String',
:'url' => :'String',
:'summary' => :'UploadSummary',
:'created_at' => :'DateTime',
:'updated_at' => :'DateTime'
Expand Down Expand Up @@ -87,6 +92,10 @@ def initialize(attributes = {})
self.tag = attributes[:'tag']
end

if attributes.key?(:'url')
self.url = attributes[:'url']
end

if attributes.key?(:'summary')
self.summary = attributes[:'summary']
end
Expand Down Expand Up @@ -123,6 +132,7 @@ def ==(o)
format == o.format &&
state == o.state &&
tag == o.tag &&
url == o.url &&
summary == o.summary &&
created_at == o.created_at &&
updated_at == o.updated_at
Expand All @@ -137,7 +147,7 @@ def eql?(o)
# Calculates hash code according to all attributes.
# @return [Integer] Hash code
def hash
[id, filename, format, state, tag, summary, created_at, updated_at].hash
[id, filename, format, state, tag, url, summary, created_at, updated_at].hash
end

# Builds the object from hash
Expand Down
6 changes: 6 additions & 0 deletions spec/models/upload_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@
end
end

describe 'test attribute "url"' do
it 'should work' do
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
end
end

describe 'test attribute "summary"' do
it 'should work' do
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
Expand Down

0 comments on commit 0d0e49a

Please sign in to comment.