Sha256: d6bc1d12cb1dd8216806b22f7fac9c72b73291c2f5326bd7881c55fc7b050a60

Contents?: true

Size: 546 Bytes

Versions: 9

Compression:

Stored size: 546 Bytes

Contents

# frozen_string_literal: true

require 'test_helper'

module Vedeu

  class ViewTestClass

    include Vedeu::View

  end # ViewTestClass

  describe View do

    let(:described) { Vedeu::ViewTestClass }
    let(:instance)  { described.new }

    describe '#time_now' do
      let(:_time) { Time.new(2015, 6, 23, 22, 25, 17) }

      before { Time.stubs(:now).returns(_time) }

      subject { instance.time_now }

      it 'returns a formatted time' do
        subject.must_equal('Tue 23 Jun 22:25')
      end
    end

  end # View

end # Vedeu

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
vedeu-0.8.9 test/lib/vedeu/application/view_test.rb
vedeu-0.8.8 test/lib/vedeu/application/view_test.rb
vedeu-0.8.7 test/lib/vedeu/application/view_test.rb
vedeu-0.8.6 test/lib/vedeu/application/view_test.rb
vedeu-0.8.5 test/lib/vedeu/application/view_test.rb
vedeu-0.8.4 test/lib/vedeu/application/view_test.rb
vedeu-0.8.3 test/lib/vedeu/application/view_test.rb
vedeu-0.8.2 test/lib/vedeu/application/view_test.rb
vedeu-0.8.1 test/lib/vedeu/application/view_test.rb