Sha256: 202df2bf8f3d34fcfd65b4e51f0dfb5b67f0260decd4892f6704e30054700fd4

Contents?: true

Size: 474 Bytes

Versions: 46

Compression:

Stored size: 474 Bytes

Contents

# encoding: utf-8

require 'spec_helper'

describe Github::Validations::Token do

  let(:validator) { Class.new.extend(described_class) }

  context '#validates_token_for' do
    it 'does not require authentication token' do
      validator.validates_token_for(:get, '/octocat/emails').should be_false
    end

    it 'requires authentication token' do
      validator.validates_token_for(:get, '/user/emails').should be_true
    end
  end

end # Github::Validations::Token

Version data entries

46 entries across 46 versions & 1 rubygems

Version Path
github_api-0.12.3 spec/github/validations/token_spec.rb
github_api-0.12.2 spec/github/validations/token_spec.rb
github_api-0.12.1 spec/github/validations/token_spec.rb
github_api-0.12.0 spec/github/validations/token_spec.rb
github_api-0.11.3 spec/github/validations/token_spec.rb
github_api-0.11.2 spec/github/validations/token_spec.rb
github_api-0.11.1 spec/github/validations/token_spec.rb
github_api-0.11.0 spec/github/validations/token_spec.rb
github_api-0.10.2 spec/github/validations/token_spec.rb
github_api-0.10.1 spec/github/validations/token_spec.rb
github_api-0.10.0 spec/github/validations/token_spec.rb
github_api-0.9.7 spec/github/validations/token_spec.rb
github_api-0.9.6 spec/github/validations/token_spec.rb
github_api-0.9.5 spec/github/validations/token_spec.rb
github_api-0.9.4 spec/github/validations/token_spec.rb
github_api-0.9.3 spec/github/validations/token_spec.rb
github_api-0.9.2 spec/github/validations/token_spec.rb
github_api-0.9.1 spec/github/validations/token_spec.rb
github_api-0.9.0 spec/github/validations/token_spec.rb
github_api-0.8.11 spec/github/validations/token_spec.rb