def test_load_all(self):
        # Arrange
        mock_client = MagicMock()

        with open(TEST_PATH + "instruments.json") as response:
            instruments = json.load(response)

        mock_client.request.return_value = instruments

        provider = OandaInstrumentProvider(client=mock_client, account_id="001")

        # Act
        provider.load_all()

        # Assert
        self.assertTrue(provider.count > 0)  # No exceptions raised
    def test_get_all_when_loaded_returns_instruments(self):
        # Arrange
        mock_client = MagicMock()

        with open(TEST_PATH + "instruments.json") as response:
            instruments = json.load(response)

        mock_client.request.return_value = instruments

        provider = OandaInstrumentProvider(client=mock_client, account_id="001")
        provider.load_all()

        # Act
        instruments = provider.get_all()

        # Assert
        self.assertTrue(len(instruments) > 0)
        self.assertEqual(dict, type(instruments))
        self.assertEqual(InstrumentId, type(next(iter(instruments))))