docstr: test finding records by date
docstr_tok: ["test","finding","records","by","date"]
code: def test_find_records_dt(self):
      """test finding records by date"""
      hist = self.db.get_history()
      middle = self.db.get_record(hist[len(hist) // 2])
      tic = middle["submitted"]
      before = self.db.find_records({"submitted": {"$lt": tic}})
      after = self.db.find_records({"submitted": {"$gte": tic}})
      assert len(before) + len(after) == len(hist)
      for b in before:
          assert b["submitted"] < tic
      for a in after:
          assert a["submitted"] >= tic
      same = self.db.find_records({"submitted": tic})
      for s in same:
          assert s["submitted"] == tic
  
imports: import logging
  import os
  import tempfile
  import time
  from datetime import datetime, timedelta
  from unittest import TestCase
  import pytest
  from jupyter_client.session import Session
  from ipyparallel import util
  from ipyparallel.controller.dictdb import DictDB
  from ipyparallel.controller.hub import init_record
  from ipyparallel.controller.sqlitedb import SQLiteDB
  from ipyparallel.util import utc
label_desc: Use image node_id 8 for calling the TaskDBTest obj's underlying member method code with example usage: obj.test_find_records_dt() without return types