<commit_before>import unittest
from ykman.util import TRANSPORT
from .util import (DestructiveYubikeyTestCase, missing_mode, ykman_cli)


@unittest.skipIf(*missing_mode(TRANSPORT.U2F))
class TestFidoFunctions(DestructiveYubikeyTestCase):

    def test_fido_set_pin(self):
        output = ykman_cli('--log-level', 'DEBUG', 'fido', 'info')
        self.assertIn('PIN is not set.', output)
        ykman_cli('fido', 'set-pin', '--new-pin', '123abc')
        output = ykman_cli('fido', 'info')
        self.assertIn('PIN is set', output)<commit_msg>fido: update test<commit_after>import unittest
from ykman.util import TRANSPORT
from .util import (DestructiveYubikeyTestCase, missing_mode, ykman_cli)


@unittest.skipIf(*missing_mode(TRANSPORT.U2F))
class TestFidoFunctions(DestructiveYubikeyTestCase):

    def test_fido_set_pin(self):
        output = ykman_cli('fido', 'info')
        self.assertIn('PIN is not set.', output)
        ykman_cli('fido', 'set-pin', '--new-pin', '123abc')
        output = ykman_cli('fido', 'info')
        self.assertIn('PIN is set', output)
{'fraction_non_alphanumeric': 0.13805970149253732, 'fraction_numerical': 0.007462686567164179, 'mean_word_length': 4.41919191919192, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '216317', 'n_tokens_mistral': 390, 'n_tokens_neox': 376, 'n_words': 75}