Sha256: ec72c9a08ff15f95916d23eea51c6f3ffee5389f580f84f0a9a9a1f2bbb51ed6
Contents?: true
Size: 968 Bytes
Versions: 3
Compression:
Stored size: 968 Bytes
Contents
require 'spec_helper' require_relative '../../../lib/locomotive/steam/middlewares/thread_safe' require_relative '../../../lib/locomotive/steam/middlewares/concerns/helpers' require_relative '../../../lib/locomotive/steam/middlewares/auth' describe Locomotive::Steam::Middlewares::Auth::AuthOptions do let(:metafields) { { 'smtp' => { 'address' => '127.0.0.1', 'user_name' => 'John', 'password' => 'doe', 'port' => 25 } } } let(:site) { instance_double('Site', metafields: metafields) } let(:params) { {} } let(:options) { described_class.new(site, params) } describe '#smtp' do subject { options.smtp } it { is_expected.to eq( address: '127.0.0.1', user_name: 'John', password: 'doe', port: 25, authentication: 'plain', enable_starttls_auto: false, ) } context 'no smtp metafields' do let(:metafields) { {} } it { is_expected.to eq({}) } end end end
Version data entries
3 entries across 3 versions & 1 rubygems