def test_mappings(self):
     w = Wiremock(host="localhost", port=8080)
     w.delete_all_mappings()
     w.add_mapping({
         "request": {
             "method": "GET",
             "url": "/some/thing/to/delete"
         },
         "response": {
             "status": 200,
             "body": "Hello world!",
             "headers": {
                 "Content-Type": "text/plain"
             }
         }
     })
     mappings = w.mappings()
     self.assertTrue(isinstance(mappings, list))
     self.assertEqual(len(mappings), 1)
 def test_populate_from_dir(self):
     w = Wiremock(host="localhost", port=8080)
     w.delete_all_mappings()
     self.assertEqual(len(w.populate_from_dir('./tests/mappings')), 2)
     mappings = w.mappings()
     self.assertEqual(len(mappings), 2)