From c3f71a1692599105ab1a0ece767061484c6119f8 Mon Sep 17 00:00:00 2001 From: Matthew Kienow Date: Wed, 9 Jan 2019 23:56:16 -0500 Subject: [PATCH] Update Rspec expected thread count When REMOTE_DB is set there is a thread for the web service, in addition to the External modules thread manager, so there is one or two threads by the end of the test run in addition to the main VM thread. --- lib/metasploit/framework/spec/threads/suite.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/metasploit/framework/spec/threads/suite.rb b/lib/metasploit/framework/spec/threads/suite.rb index 3033679f4f..dcee3034a7 100644 --- a/lib/metasploit/framework/spec/threads/suite.rb +++ b/lib/metasploit/framework/spec/threads/suite.rb @@ -12,7 +12,7 @@ module Metasploit # # Number of allowed threads when threads are counted in `after(:suite)` or `before(:suite)` - EXPECTED_THREAD_COUNT_AROUND_SUITE = 2 + EXPECTED_THREAD_COUNT_AROUND_SUITE = ENV['REMOTE_DB'] ? 3 : 2 # `caller` for all Thread.new calls LOG_PATHNAME = Pathname.new('log/metasploit/framework/spec/threads/suite.log')