spiegel-keyman/common/test/keyboards/invalid
2023-01-19 14:10:18 +01:00
..
source chore(developer): remove some unnecessary CERR_ tests 2023-01-10 16:30:21 +01:00
README.md chore(developer): restored kmcompxtest, adapted readme 2023-01-19 14:10:18 +01:00

Tests for kmcompxtest()


This folder contains several kmn-files that are used for testing resulting error codes.

Most of these tests are copied from balochi_phonetic and contain alterations of the data to produce (at least) 1 error.


Naming Convention of kmn-files for using with kmcompxtest()

CERR_404D_balochi_phonetic.kmn

The naming convention of the files is as follows:

  • All Files MUST start with CERR_ followed by 4 characters and an underscore.

  • After the second underscore all combination of char can be used.

  • The 4 characters following CERR_ correspond to the last 4 digits of the error-Code which is expected to be produced by this file.

    ( e.g. CERR_404D_balochi_phonetic.kmn should produce error 0x0000404D).




While running, kmcompxtest extracts those 4 characters from the Filename (e.g. 404D for CERR_404D_balochi_phonetic) and compares those to the actual error found.

  • If these 4 characters correspond to the actual error given, the test will be marked as OK. (Code 0)
  • If these 4 characters signifiy an error but no error does occur, the test will be marked as FAILED (Code 1)
  • If these 4 characters signifiy an error but this specific error does not occur, the test will be marked as FAILED (Code 4)
  • If these 4 characters signifiy an error number that is not correct, the test will be marked as FAILED (Code 5)
  • If more than 1 error is produced, only the error coded in the Filename will be detected

Tests are available for the following CERR_:

( )   00000800   CERR_LEXICAL_MODEL_MIN ( )   000008FF   CERR_LEXICAL_MODEL_MAX ( )   00000000   CERR_None ( )   00000001   CERR_EndOfFile ( )   00008002   CERR_BadCallParams ( )   00008004   CERR_CannotAllocateMemory ( )   00008005   CERR_InfileNotExist ( )   00008006   CERR_CannotCreateOutfile ( )   00008007   CERR_UnableToWriteFully ( )   00008008   CERR_CannotReadInfile ( )   00008009   CERR_SomewhereIGotItWrong ( x )   0000400A   CERR_InvalidToken ( )   0000400B   CERR_InvalidBegin ( )   0000400C   CERR_InvalidName ( x )   0000400D   CERR_InvalidVersion ( x )   0000400E   CERR_InvalidLanguageLine ( )   0000400F   CERR_LayoutButNoLanguage ( )   00004010   CERR_InvalidLayoutLine ( )   00004011   CERR_NoVersionLine ( )   00004012   CERR_InvalidGroupLine ( x )   00004013   CERR_InvalidStoreLine ( )   00004014   CERR_InvalidCodeInKeyPartOfRule ( x )   00004015   CERR_InvalidDeadkey ( x )   00004016   CERR_InvalidValue ( x )   00004017   CERR_ZeroLengthString ( )   00004018   CERR_TooManyIndexToKeyRefs ( x )   00004019   CERR_UnterminatedString ( )   0000401A   CERR_StringInVirtualKeySection ( )   0000401B   CERR_AnyInVirtualKeySection ( )   0000401C   CERR_InvalidAny ( x )   0000401D   CERR_StoreDoesNotExist ( )   0000401E   CERR_BeepInVirtualKeySection ( )   0000401F   CERR_IndexInVirtualKeySection ( )   00004020   CERR_InvalidIndex ( )   00004021   CERR_OutsInVirtualKeySection ( )   00004022   CERR_InvalidOuts ( )   00004024   CERR_ContextInVirtualKeySection ( )   00004025   CERR_InvalidUse ( x )   00004026   CERR_GroupDoesNotExist ( )   00004027   CERR_VirtualKeyNotAllowedHere ( )   00004028   CERR_InvalidSwitch ( x )   00004029   CERR_NoTokensFound ( )   0000402A   CERR_InvalidLineContinuation ( x )   0000402B   CERR_LineTooLong ( )   0000402C   CERR_InvalidCopyright ( x )   0000402D   CERR_CodeInvalidInThisSection ( )   0000402E   CERR_InvalidMessage ( )   0000402F   CERR_InvalidLanguageName ( )   00004030   CERR_InvalidBitmapLine ( x )   00004031   CERR_CannotReadBitmapFile ( )   00004032   CERR_IndexDoesNotPointToAny ( )   00004033   CERR_ReservedCharacter ( x )   00004034   CERR_InvalidCharacter ( )   00004035   CERR_InvalidCall ( )   00004036   CERR_CallInVirtualKeySection ( )   00004037   CERR_CodeInvalidInKeyStore ( x )   00004038   CERR_CannotLoadIncludeFile ( x )   00004039   CERR_60FeatureOnly_EthnologueCode ( x )   0000403A   CERR_60FeatureOnly_MnemonicLayout ( )   0000403B   CERR_60FeatureOnly_OldCharPosMatching ( )   0000403C   CERR_60FeatureOnly_NamedCodes ( )   0000403D   CERR_60FeatureOnly_Contextn ( x )   0000403E   CERR_501FeatureOnly_Call ( )   0000403F   CERR_InvalidNamedCode ( x )   00004040   CERR_InvalidSystemStore ( x )   00004044   CERR_60FeatureOnly_VirtualCharKey ( x )   00004045   CERR_VersionAlreadyIncluded ( x )   00004046   CERR_70FeatureOnly ( x )   00004047   CERR_80FeatureOnly ( )   00004048   CERR_InvalidInVirtualKeySection ( x )   00004049   CERR_InvalidIf ( x )   0000404A   CERR_InvalidReset ( x )   0000404B   CERR_InvalidSet ( x )   0000404C   CERR_InvalidSave ( x )   0000404D   CERR_InvalidEthnologueCode ( )   0000804E   CERR_CannotCreateTempfile ( x )   0000404F   CERR_90FeatureOnly_IfSystemStores ( )   00004050   CERR_IfSystemStore_NotFound ( )   00004051   CERR_90FeatureOnly_SetSystemStores ( )   00004052   CERR_SetSystemStore_NotFound ( )   00004053   CERR_90FeatureOnlyVirtualKeyDictionary ( )   00004054   CERR_NotSupportedInKeymanWebContext ( )   00004055   CERR_NotSupportedInKeymanWebOutput ( )   00004056   CERR_NotSupportedInKeymanWebStore ( )   00004057   CERR_VirtualCharacterKeysNotSupportedInKeymanWeb ( )   00004058   CERR_VirtualKeysNotValidForMnemonicLayouts ( )   00004059   CERR_InvalidTouchLayoutFile ( )   0000405A   CERR_TouchLayoutInvalidIdentifier ( )   0000405B   CERR_InvalidKeyCode ( x )   0000405C   CERR_90FeatureOnlyLayoutFile ( x )   0000405D   CERR_90FeatureOnlyKeyboardVersion ( x )   0000405E   CERR_KeyboardVersionFormatInvalid ( )   0000405F   CERR_ContextExHasInvalidOffset ( x )   00004060   CERR_90FeatureOnlyEmbedCSS ( x )   00004061   CERR_90FeatureOnlyTargets ( )   00004062   CERR_ContextAndIndexInvalidInMatchNomatch ( )   00004063   CERR_140FeatureOnlyContextAndNotAnyWeb ( x )   00004064   CERR_ExpansionMustFollowCharacterOrVKey ( )   00004065   CERR_VKeyExpansionMustBeFollowedByVKey ( )   00004066   CERR_CharacterExpansionMustBeFollowedByCharacter ( )   00004067   CERR_VKeyExpansionMustUseConsistentShift ( )   00004068   CERR_ExpansionMustBePositive ( )   00004069   CERR_CasedKeysMustContainOnlyVirtualKeys ( )   0000406A   CERR_CasedKeysMustNotIncludeShiftStates ( )   0000406B   CERR_CasedKeysNotSupportedWithMnemonicLayout ( )   0000406C   CERR_CannotUseReadWriteGroupFromReadonlyGroup ( )   0000406D   CERR_StatementNotPermittedInReadonlyGroup ( )   0000406E   CERR_OutputInReadonlyGroup ( )   0000406F   CERR_NewContextGroupMustBeReadonly ( )   00004070   CERR_PostKeystrokeGroupMustBeReadonly ( x )   00004071   CERR_DuplicateGroup ( x )   00004072   CERR_DuplicateStore ( x )   00004073   CERR_RepeatedBegin