def test_exposure_type_choices_returns_valid_attributes(): choices = ExposureType.choices() valid_set = { "SharedViaLink", "SharedToDomain", "ApplicationRead", "CloudStorage", "RemovableMedia", "IsPublic", "OutsideTrustedDomains", } assert set(choices) == valid_set
SEARCH_DEFAULT_HEADER["fileOwner"] = "FileOwner" SEARCH_DEFAULT_HEADER["md5Checksum"] = "MD5Checksum" SEARCH_DEFAULT_HEADER["sha256Checksum"] = "SHA256Checksum" file_events_format_option = click.option( "-f", "--format", type=click.Choice(enum.FileEventsOutputFormat(), case_sensitive=False), help="The output format of the result. Defaults to table format.", default=enum.FileEventsOutputFormat.TABLE, ) exposure_type_option = click.option( "-t", "--type", multiple=True, type=click.Choice(list(ExposureType.choices())), cls=searchopt.AdvancedQueryAndSavedSearchIncompatible, callback=searchopt.is_in_filter(f.ExposureType), help="Limits events to those with given exposure types.", ) username_option = click.option( "--c42-username", multiple=True, callback=searchopt.is_in_filter(f.DeviceUsername), cls=searchopt.AdvancedQueryAndSavedSearchIncompatible, help="Limits events to endpoint events for these Code42 users.", ) actor_option = click.option( "--actor", multiple=True, callback=searchopt.is_in_filter(f.Actor),