Sha256: 3b659a5fe69143886a08c74deb1e3447d0afd0b7d10a711282869a081cd047cc
Contents?: true
Size: 855 Bytes
Versions: 18
Compression:
Stored size: 855 Bytes
Contents
# frozen_string_literal: true # encoding: utf-8 require 'spec_helper' describe Mongo::Auth::LDAP::Conversation do let(:user) do Mongo::Auth::User.new( database: '$external', user: 'user', password: 'pencil' ) end let(:conversation) do described_class.new(user, double('connection')) end describe '#start' do let(:query) do conversation.start(nil) end let(:selector) do query.selector end it 'sets the sasl start flag' do expect(selector[:saslStart]).to eq(1) end it 'sets the auto authorize flag' do expect(selector[:autoAuthorize]).to eq(1) end it 'sets the mechanism' do expect(selector[:mechanism]).to eq('PLAIN') end it 'sets the payload' do expect(selector[:payload].data).to eq("\x00user\x00pencil") end end end
Version data entries
18 entries across 18 versions & 1 rubygems