diff --git a/spec/support/shared/examples/lib/metasploit/framework/login_scanner/login_scanner_base.rb b/spec/support/shared/examples/lib/metasploit/framework/login_scanner/login_scanner_base.rb index e00e59f6df..aa480c2f4c 100644 --- a/spec/support/shared/examples/lib/metasploit/framework/login_scanner/login_scanner_base.rb +++ b/spec/support/shared/examples/lib/metasploit/framework/login_scanner/login_scanner_base.rb @@ -84,7 +84,7 @@ shared_examples_for 'Metasploit::Framework::LoginScanner::Base' do end it 'is not valid for a number greater than 65535' do - login_scanner.port = rand(1000) + 65535 + login_scanner.port = 65536 expect(login_scanner).to_not be_valid expect(login_scanner.errors[:port]).to include "must be less than or equal to 65535" end @@ -332,4 +332,4 @@ shared_examples_for 'Metasploit::Framework::LoginScanner::Base' do end end -end \ No newline at end of file +end