Skip to content

Commit

Permalink
Merge pull request #4197 from sanger/sh51/last-minute-lint-fixes
Browse files Browse the repository at this point in the history
style: lint prettier
  • Loading branch information
StephenHulme authored Jul 10, 2024
2 parents fa00b74 + e3bb5ef commit 28f96c4
Show file tree
Hide file tree
Showing 6 changed files with 15 additions and 15 deletions.
4 changes: 2 additions & 2 deletions app/resources/api/v2/asset_audit_resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class AssetAuditResource < BaseResource

# @!attribute metadata
# @return [Hash] the metadata of the asset audit.
attribute :metadata # Currently known clients (AssetAudits app) are sending null; unsure of the expected format.
attribute :metadata # Currently known clients (AssetAudits app) are sending null; unsure of the expected format.

# Sets the Asset on the model using the UUID provided in the API create/update request.
#
Expand All @@ -51,7 +51,7 @@ def asset_uuid
# @param _context [JSONAPI::Resource::Context] not used.
# @return [Array<Symbol>] the list of updatable fields.
def self.updatable_fields(_context)
[] # Do not allow updating any fields.
[] # Do not allow updating any fields.
end
end
end
Expand Down
4 changes: 2 additions & 2 deletions app/resources/api/v2/plate_purpose_resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -78,15 +78,15 @@ def input_plate
# @param _context [JSONAPI::Resource::Context] not used
# @return [Array<Symbol>] the list of creatable fields.
def self.creatable_fields(_context)
super - %i[input_plate uuid] # Do not allow creating with any readonly fields
super - %i[input_plate uuid] # Do not allow creating with any readonly fields
end

# Gets the list of fields which are updatable on an existing PlatePurpose.
#
# @param _context [JSONAPI::Resource::Context] not used
# @return [Array<Symbol>] the list of updatable fields.
def self.updatable_fields(_context)
[] # Do not allow updating any fields.
[] # Do not allow updating any fields.
end
end
end
Expand Down
2 changes: 1 addition & 1 deletion app/resources/api/v2/volume_update_resource.rb
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def target_uuid
# @param _context [JSONAPI::Resource::Context] not used.
# @return [Array<Symbol>] the list of updatable fields.
def self.updatable_fields(_context)
[] # Do not allow updating any fields.
[] # Do not allow updating any fields.
end
end
end
Expand Down
8 changes: 4 additions & 4 deletions spec/requests/api/v2/asset_audits_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
'id' => resource_model.id,
'type' => 'asset_audits',
'attributes' => {
'witnessed_by' => updated_witnessed_by,
'witnessed_by' => updated_witnessed_by
}
}
}
Expand All @@ -40,7 +40,7 @@
expect(response).to have_http_status(:success)
expect(json.dig('data', 'type')).to eq('asset_audits')
expect(json.dig('data', 'attributes', 'key')).to eq(resource_model.key)
expect(json.dig('data', 'attributes','witnessed_by')).to eq(resource_model.witnessed_by)
expect(json.dig('data', 'attributes', 'witnessed_by')).to eq(resource_model.witnessed_by)
end

it 'does not allow update of an AssetAudit' do
Expand All @@ -62,8 +62,8 @@
'message' => 'This is a test message',
'created_by' => 'test_user',
'asset_uuid' => labware.uuid,
'witnessed_by' => 'witness_user',
},
'witnessed_by' => 'witness_user'
}
}
}
end
Expand Down
6 changes: 3 additions & 3 deletions spec/requests/api/v2/plate_purposes_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
'id' => resource_model.id,
'type' => 'plate_purposes',
'attributes' => {
'size' => updated_size,
'size' => updated_size
}
}
}
Expand Down Expand Up @@ -62,8 +62,8 @@
'stock_plate' => true,
'cherrypickable_target' => false,
'size' => 384,
'asset_shape' => asset_shape.name,
},
'asset_shape' => asset_shape.name
}
}
}
end
Expand Down
6 changes: 3 additions & 3 deletions spec/requests/api/v2/volume_update_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
'id' => resource_model.id,
'type' => 'volume_updates',
'attributes' => {
'volume_change' => updated_volume_change,
'volume_change' => updated_volume_change
}
}
}
Expand Down Expand Up @@ -59,8 +59,8 @@
'attributes' => {
'volume_change' => 5.0,
'created_by' => 'test_user',
'target_uuid' => plate.uuid,
},
'target_uuid' => plate.uuid
}
}
}
end
Expand Down

0 comments on commit 28f96c4

Please sign in to comment.