summaryrefslogtreecommitdiff
path: root/spec/models/exercise_spec.rb
blob: cd9fb9c7ef7859320c6eec3af8aa375fd3bc2a84 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
require "rails_helper"

describe Exercise do
  describe "#short_name" do
    it "returns the acronym for the exercise" do
      expect(build(:exercise, name: "Squat").short_name).to eql("S")
      expect(build(:exercise, name: "Bench Press").short_name).to eql("BP")
      expect(build(:exercise, name: "Deadlift").short_name).to eql("D")
      expect(build(:exercise, name: "Overhead Press").short_name).to eql("OP")
    end
  end
end