From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmx.net header.s=badeba3b8450 header.b=iskLF3Wq; spf=pass (domain: gmx.de, ip: 212.227.15.19, mailfrom: xypron.glpk@gmx.de) Received: from mout.gmx.net (mout.gmx.net [212.227.15.19]) by groups.io with SMTP; Wed, 04 Sep 2019 14:34:10 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1567632838; bh=yW5ExgMbOp1yCMCcLyRmGI1lrDc0VxLjhJUsXsQ6cOM=; h=X-UI-Sender-Class:From:To:Cc:Subject:Date; b=iskLF3Wq2W8d+WpyjZtEH5sJBfMM+aQpqIbwChPh8dEMIHSWkFXNXsTXkjJQiFhE6 F1T1JCPbI/mnhLmphVe5V9nfTqvBnA+DjPkJK76M7WkIGt3j64phyP2PbeAn/hVUXk G36CX0jsx99fSchWTidqs4jBouh/RaXKWHMi+Csg= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from localhost.localdomain ([84.118.159.3]) by mail.gmx.com (mrgmx002 [212.227.17.184]) with ESMTPSA (Nemesis) id 0LdYxu-1iWgCq1ElG-00ilva; Wed, 04 Sep 2019 23:33:58 +0200 From: "Heinrich Schuchardt" To: EDK II Development Cc: Eric Jin , Supreeth Venkatesh , Stephano Cetola , Heinrich Schuchardt Subject: [edk2-test] [PATCH 1/1] uefi-sct/SctPkg: setting key toggle state may be unsupported Date: Wed, 4 Sep 2019 23:33:50 +0200 Message-Id: <20190904213350.1239-1-xypron.glpk@gmx.de> X-Mailer: git-send-email 2.23.0.rc1 MIME-Version: 1.0 X-Provags-ID: V03:K1:k0ldgWFfzhoaqgJa2ZOHvpRXKAO01zT9qHtzUId818m4cKBicrz 82wfzCa8qLQg4Xj3fz6aTSFFxk0yyQXhy8U6J8sysMhKndiKWeOZeXJzSijzheWfNVmcxg/ s11ay+jXx5f51AsyVwJNypMEgMYxjTgUGuFkD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+F2L+aFEb IvqwTgiRtsFi2Bsi3f0QnaKmq4Pe8esfqQbo/zhRzQwYtf+saIWCuHjC0c7y8xwGoLJt09DM6 1rAr7aEJQXa781qbVKPUgJ/7p+a5IpUujoJXK3E0uJF4FUoiR1Qq618hS1Skl/1rH5UoVxC/U mqO3/d1Gj4wEtDhVw0b8MwFsPlfldK6OiZ4YeKapPp3QqV5lnoM151gqfY7/sf96l0Tq2USvs TwEMJqZ7qNTSjV4jnz8uCewm9hdOqzjltyaxfm2d/u9kZxqFzNBBrXpUqPxP1P4Hv11CgPZj1 pjmIUs2taOoekmzu+ Content-Transfer-Encoding: quoted-printable It is allowable that a system does not support EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL.SetState(). For instance a serial console would not allow to set toggle keys. In this case do not expect the function to check its arguments. It will typically directly return EFI_UNSUPPORTED. Signed-off-by: Heinrich Schuchardt --- .../SimpleTextInputExBBTestConformance.c | 37 ++++++++++++------- 1 file changed, 23 insertions(+), 14 deletions(-) diff --git a/uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/SimpleTextInputEx/B= lackBoxTest/SimpleTextInputExBBTestConformance.c b/uefi-sct/SctPkg/TestCase= /UEFI/EFI/Protocol/SimpleTextInputEx/BlackBoxTest/SimpleTextInputExBBTestCo= nformance.c index d997b651..7876d8db 100644 --- a/uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/SimpleTextInputEx/BlackBox= Test/SimpleTextInputExBBTestConformance.c +++ b/uefi-sct/SctPkg/TestCase/UEFI/EFI/Protocol/SimpleTextInputEx/BlackBox= Test/SimpleTextInputExBBTestConformance.c @@ -483,22 +483,31 @@ BBTestSetStateConformanceTestCheckpoint1 ( );=0D }=0D }=0D - =0D - if ( EFI_INVALID_PARAMETER !=3D Status) {=0D - AssertionType =3D EFI_TEST_ASSERTION_FAILED;=0D +=0D + if (Status =3D=3D EFI_UNSUPPORTED) {=0D + StandardLib->RecordMessage(=0D + StandardLib,=0D + EFI_VERBOSE_LEVEL_QUIET,=0D + L"SetState isn't supported, Status - %r\n",=0D + Status=0D + );=0D } else {=0D - AssertionType =3D EFI_TEST_ASSERTION_PASSED;=0D + if ( EFI_INVALID_PARAMETER !=3D Status) {=0D + AssertionType =3D EFI_TEST_ASSERTION_FAILED;=0D + } else {=0D + AssertionType =3D EFI_TEST_ASSERTION_PASSED;=0D + }=0D + StandardLib->RecordAssertion (=0D + StandardLib,=0D + AssertionType,=0D + gSimpleTextInputExBBTestConformanceAssertionGuid003,=0D + L"SIMPLE_TEXT_INPUT_EX_PROTOCOL.SetState - SetState() returns= EFI_INVALID_PARAMETER with KeyToggleState being NULL.",=0D + L"%a:%d: Status - %r",=0D + __FILE__,=0D + (UINTN)__LINE__,=0D + Status=0D + );=0D }=0D - StandardLib->RecordAssertion (=0D - StandardLib,=0D - AssertionType,=0D - gSimpleTextInputExBBTestConformanceAssertionGuid003,=0D - L"SIMPLE_TEXT_INPUT_EX_PROTOCOL.SetState - SetState() returns E= FI_INVALID_PARAMETER with KeyToggleState being NULL.",=0D - L"%a:%d: Status - %r",=0D - __FILE__,=0D - (UINTN)__LINE__,=0D - Status=0D - );=0D =0D return EFI_SUCCESS;=0D }=0D --=20 2.23.0.rc1