Sha256: 0909c4ab70aee06c8542e622c77dabc0ce309db5b48913dbc3d653b933116321
Contents?: true
Size: 979 Bytes
Versions: 2
Compression:
Stored size: 979 Bytes
Contents
require 'spec_helper' module NotifyUser describe APNConnection do describe 'pem file paths' do before :each do @connection = described_class.new end it 'has the correct default development path' do expect(@connection.send(:development_certificate)).to eq "#{Rails.root}/config/keys/development_push.pem" end it 'has the correct default production path' do expect(@connection.send(:production_certificate)).to eq "#{Rails.root}/config/keys/production_push.pem" end it 'can set a custom path for development' do ENV['APN_DEVELOPMENT_PATH'] = 'path/to/key.pem' expect(@connection.send(:development_certificate)).to eq "#{Rails.root}/path/to/key.pem" end it 'can set a custom path for production' do ENV['APN_PRODUCTION_PATH'] = 'path/to/key.pem' expect(@connection.send(:production_certificate)).to eq "#{Rails.root}/path/to/key.pem" end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
notify_user-0.3.2 | spec/models/notify_user/apn_connection_spec.rb |
notify_user-0.3.1 | spec/models/notify_user/apn_connection_spec.rb |