class_docstr: Test InMemoryDocumentStore's specific features
class_docstr_tok: ["Test","InMemoryDocumentStore","'s","specific","features"]
code: def test_from_dict(self, mock_regex):
      data = {
          "type": "haystack.document_stores.in_memory.document_store.InMemoryDocumentStore",
          "init_parameters": {
              "bm25_tokenization_regex": "custom_regex",
              "bm25_algorithm": "BM25Plus",
              "bm25_parameters": {"key": "value"},
          },
      }
      store = InMemoryDocumentStore.from_dict(data)
      mock_regex.compile.assert_called_with("custom_regex")
      assert store.tokenizer
      assert store.bm25_algorithm.__name__ == "BM25Plus"
      assert store.bm25_parameters == {"key": "value"}
  
imports: import logging
  from unittest.mock import patch
  import pandas
  import pytest
  from haystack import Document
  from haystack.document_stores.errors import DocumentStoreError, DuplicateDocumentError
  from haystack.document_stores.in_memory import InMemoryDocumentStore
  from haystack.testing.document_store import DocumentStoreBaseTests
label_desc: Use image node_id 4 for calling the TestMemoryDocumentStore obj's underlying member method code with example usage: obj.test_from_dict(mock_regex) without return types