code: def test_get_filenames_in_tag__exclude_parent_tag(
      mocker: MockerFixture,
  ) -> None:
      prev_tag_id = utils.generate_id()
      dataset_id = utils.generate_id()
      tag = _get_tags(dataset_id=dataset_id, prev_tag_id=prev_tag_id)[0]
      mocker.patch.object(
          ApiWorkflowClient, "__init__", return_value=None
      )
      mocked_get_filenames = mocker.patch.object(
          ApiWorkflowClient,
          "get_filenames",
          return_value=[f"file{i}" for i in range(3)],
      )
      mocked_response = mocker.MagicMock()
      mocked_response.bit_mask_data = "0x2"
      mocked_tag_arithmetics = mocker.MagicMock(
          return_value=mocked_response
      )
      mocked_api = mocker.MagicMock()
      mocked_api.perform_tag_arithmetics_bitmask = (
          mocked_tag_arithmetics
      )
  
      client = ApiWorkflowClient()
      client._dataset_id = dataset_id
      client._tags_api = mocked_api
      result = client.get_filenames_in_tag(
          tag_data=tag, exclude_parent_tag=True
      )
      assert result == ["file1"]
      mocked_get_filenames.assert_called_once()
      mocked_tag_arithmetics.assert_called_once()
      kwargs = mocked_tag_arithmetics.call_args[1]
      assert kwargs["dataset_id"] == dataset_id
      assert kwargs["tag_arithmetics_request"].tag_id2 == prev_tag_id
  
file_path: lightly/tests/api_workflow/test_api_workflow_tags.py
imports: from typing import List, Optional
  import pytest
  from pytest_mock import MockerFixture
  from lightly.api import ApiWorkflowClient
  from lightly.api.api_workflow_tags import TagDoesNotExistError
  from lightly.openapi_generated.swagger_client.models import TagCreator, TagData
  from tests.api_workflow import utils
label_desc: Use image node_id 8 for calling a global function with example usage: test_get_filenames_in_tag__exclude_parent_tag(mocker) without return types