':see: https://github.com/andresriancho/w3af/issues/2181'

def test_kb_list_shells_os_commanding_2181(self):

    w3af_core = w3afCore()
    vuln = MockVuln()
    vuln['separator'] = '&'
    vuln['os'] = 'linux'
    strategy = BasicExploitStrategy(vuln)
    shell = OSCommandingShell(strategy, w3af_core.uri_opener, w3af_core.worker_pool)
    kb.append('a', 'b', shell)
    shells = kb.get_all_shells(w3af_core=w3af_core)
    self.assertEqual(len(shells), 1)
    unpickled_shell = shells[0]
    self.assertEqual(shell, unpickled_shell)
    self.assertIs(unpickled_shell._uri_opener, w3af_core.uri_opener)
    self.assertIs(unpickled_shell.worker_pool, w3af_core.worker_pool)
    self.assertEqual(unpickled_shell.strategy.vuln, vuln)
    w3af_core.quit()
