mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
This change both speeds up specs (less strings to allocate) and helps catch cases where methods in Discourse are mutating inputs. Overall we will be migrating everything to use #frozen_string_literal: true it will take a while, but this is the first and safest move in this direction
16 lines
340 B
Ruby
16 lines
340 B
Ruby
# frozen_string_literal: true
|
|
|
|
require 'rails_helper'
|
|
|
|
describe CategoryUploadSerializer do
|
|
|
|
let(:upload) { Fabricate(:upload) }
|
|
let(:subject) { described_class.new(upload, root: false) }
|
|
|
|
it 'should include width and height' do
|
|
expect(subject.width).to eq(upload.width)
|
|
expect(subject.height).to eq(upload.height)
|
|
end
|
|
|
|
end
|