test/testautomation_keyboard.c
changeset 7191 75360622e65f
parent 7172 b3569dff1c6e
child 7268 b399d0441810
     1.1 --- a/test/testautomation_keyboard.c	Sat May 18 12:48:50 2013 -0700
     1.2 +++ b/test/testautomation_keyboard.c	Sat May 18 14:17:52 2013 -0700
     1.3 @@ -15,7 +15,7 @@
     1.4  
     1.5  /**
     1.6   * @brief Check call to SDL_GetKeyboardState with and without numkeys reference.
     1.7 - * 
     1.8 + *
     1.9   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetKeyboardState
    1.10   */
    1.11  int
    1.12 @@ -24,7 +24,7 @@
    1.13     int numkeys;
    1.14     Uint8 *state;
    1.15  
    1.16 -   /* Case where numkeys pointer is NULL */    
    1.17 +   /* Case where numkeys pointer is NULL */
    1.18     state = SDL_GetKeyboardState(NULL);
    1.19     SDLTest_AssertPass("Call to SDL_GetKeyboardState(NULL)");
    1.20     SDLTest_AssertCheck(state != NULL, "Validate that return value from SDL_GetKeyboardState is not NULL");
    1.21 @@ -35,13 +35,13 @@
    1.22     SDLTest_AssertPass("Call to SDL_GetKeyboardState(&numkeys)");
    1.23     SDLTest_AssertCheck(state != NULL, "Validate that return value from SDL_GetKeyboardState is not NULL");
    1.24     SDLTest_AssertCheck(numkeys >= 0, "Validate that value of numkeys is >= 0, got: %i", numkeys);
    1.25 -   
    1.26 +
    1.27     return TEST_COMPLETED;
    1.28  }
    1.29  
    1.30  /**
    1.31   * @brief Check call to SDL_GetKeyboardFocus
    1.32 - * 
    1.33 + *
    1.34   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetKeyboardFocus
    1.35   */
    1.36  int
    1.37 @@ -58,7 +58,7 @@
    1.38  
    1.39  /**
    1.40   * @brief Check call to SDL_GetKeyFromName for known, unknown and invalid name.
    1.41 - * 
    1.42 + *
    1.43   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetKeyFromName
    1.44   */
    1.45  int
    1.46 @@ -104,19 +104,19 @@
    1.47     return TEST_COMPLETED;
    1.48  }
    1.49  
    1.50 -/* 
    1.51 +/*
    1.52   * Local helper to check for the invalid scancode error message
    1.53   */
    1.54  void
    1.55  _checkInvalidScancodeError()
    1.56  {
    1.57     const char *expectedError = "Parameter 'scancode' is invalid";
    1.58 -   const char *error;   
    1.59 +   const char *error;
    1.60     error = SDL_GetError();
    1.61     SDLTest_AssertPass("Call to SDL_GetError()");
    1.62     SDLTest_AssertCheck(error != NULL, "Validate that error message was not NULL");
    1.63     if (error != NULL) {
    1.64 -      SDLTest_AssertCheck(SDL_strcmp(error, expectedError) == 0, 
    1.65 +      SDLTest_AssertCheck(SDL_strcmp(error, expectedError) == 0,
    1.66            "Validate error message, expected: '%s', got: '%s'", expectedError, error);
    1.67        SDL_ClearError();
    1.68        SDLTest_AssertPass("Call to SDL_ClearError()");
    1.69 @@ -125,7 +125,7 @@
    1.70  
    1.71  /**
    1.72   * @brief Check call to SDL_GetKeyFromScancode
    1.73 - * 
    1.74 + *
    1.75   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetKeyFromScancode
    1.76   */
    1.77  int
    1.78 @@ -164,12 +164,12 @@
    1.79  
    1.80  /**
    1.81   * @brief Check call to SDL_GetKeyName
    1.82 - * 
    1.83 + *
    1.84   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetKeyName
    1.85   */
    1.86  int
    1.87  keyboard_getKeyName(void *arg)
    1.88 -{   
    1.89 +{
    1.90     char *result;
    1.91     char *expected;
    1.92  
    1.93 @@ -220,12 +220,12 @@
    1.94  
    1.95  /**
    1.96   * @brief SDL_GetScancodeName negative cases
    1.97 - * 
    1.98 + *
    1.99   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetScancodeName
   1.100   */
   1.101  int
   1.102  keyboard_getScancodeNameNegative(void *arg)
   1.103 -{  
   1.104 +{
   1.105     SDL_Scancode scancode;
   1.106     char *result;
   1.107     char *expected = "";
   1.108 @@ -247,12 +247,12 @@
   1.109  
   1.110  /**
   1.111   * @brief SDL_GetKeyName negative cases
   1.112 - * 
   1.113 + *
   1.114   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetKeyName
   1.115   */
   1.116  int
   1.117  keyboard_getKeyNameNegative(void *arg)
   1.118 -{  
   1.119 +{
   1.120     SDL_Keycode keycode;
   1.121     char *result;
   1.122     char *expected = "";
   1.123 @@ -284,17 +284,17 @@
   1.124  
   1.125  /**
   1.126   * @brief Check call to SDL_GetModState and SDL_SetModState
   1.127 - * 
   1.128 + *
   1.129   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetModState
   1.130   * @sa http://wiki.libsdl.org/moin.cgi/SDL_SetModState
   1.131   */
   1.132  int
   1.133  keyboard_getSetModState(void *arg)
   1.134 -{   
   1.135 +{
   1.136     SDL_Keymod result;
   1.137     SDL_Keymod currentState;
   1.138     SDL_Keymod newState;
   1.139 -   SDL_Keymod allStates =     
   1.140 +   SDL_Keymod allStates =
   1.141      KMOD_NONE |
   1.142      KMOD_LSHIFT |
   1.143      KMOD_RSHIFT |
   1.144 @@ -309,13 +309,13 @@
   1.145      KMOD_MODE |
   1.146      KMOD_RESERVED;
   1.147  
   1.148 -   /* Get state, cache for later reset */                                                   
   1.149 +   /* Get state, cache for later reset */
   1.150     result = SDL_GetModState();
   1.151     SDLTest_AssertPass("Call to SDL_GetModState()");
   1.152 -   SDLTest_AssertCheck(result >=0 && result <= allStates, "Verify result from call is valid, expected: 0 <= result <= %i, got: %i", allStates, result);   
   1.153 +   SDLTest_AssertCheck(result >=0 && result <= allStates, "Verify result from call is valid, expected: 0 <= result <= %i, got: %i", allStates, result);
   1.154     currentState = result;
   1.155  
   1.156 -   /* Set random state */   
   1.157 +   /* Set random state */
   1.158     newState = SDLTest_RandomIntegerInRange(0, allStates);
   1.159     SDL_SetModState(newState);
   1.160     SDLTest_AssertPass("Call to SDL_SetModState(%i)", newState);
   1.161 @@ -345,13 +345,13 @@
   1.162  
   1.163  /**
   1.164   * @brief Check call to SDL_StartTextInput and SDL_StopTextInput
   1.165 - * 
   1.166 + *
   1.167   * @sa http://wiki.libsdl.org/moin.cgi/SDL_StartTextInput
   1.168   * @sa http://wiki.libsdl.org/moin.cgi/SDL_StopTextInput
   1.169   */
   1.170  int
   1.171  keyboard_startStopTextInput(void *arg)
   1.172 -{   
   1.173 +{
   1.174     /* Start-Stop */
   1.175     SDL_StartTextInput();
   1.176     SDLTest_AssertPass("Call to SDL_StartTextInput()");
   1.177 @@ -361,12 +361,12 @@
   1.178     /* Stop-Start */
   1.179     SDL_StartTextInput();
   1.180     SDLTest_AssertPass("Call to SDL_StartTextInput()");
   1.181 -   
   1.182 +
   1.183     /* Start-Start */
   1.184     SDL_StartTextInput();
   1.185     SDLTest_AssertPass("Call to SDL_StartTextInput()");
   1.186  
   1.187 -   /* Stop-Stop */   
   1.188 +   /* Stop-Stop */
   1.189     SDL_StopTextInput();
   1.190     SDLTest_AssertPass("Call to SDL_StopTextInput()");
   1.191     SDL_StopTextInput();
   1.192 @@ -379,34 +379,34 @@
   1.193  void _testSetTextInputRect(SDL_Rect refRect)
   1.194  {
   1.195     SDL_Rect testRect;
   1.196 -   
   1.197 +
   1.198     testRect = refRect;
   1.199     SDL_SetTextInputRect(&testRect);
   1.200     SDLTest_AssertPass("Call to SDL_SetTextInputRect with refRect(x:%i,y:%i,w:%i,h:%i)", refRect.x, refRect.y, refRect.w, refRect.h);
   1.201     SDLTest_AssertCheck(
   1.202 -      (refRect.x == testRect.x) && (refRect.y == testRect.y) && (refRect.w == testRect.w) && (refRect.h == testRect.h), 
   1.203 -      "Check that input data was not modified, expected: x:%i,y:%i,w:%i,h:%i, got: x:%i,y:%i,w:%i,h:%i", 
   1.204 -      refRect.x, refRect.y, refRect.w, refRect.h, 
   1.205 +      (refRect.x == testRect.x) && (refRect.y == testRect.y) && (refRect.w == testRect.w) && (refRect.h == testRect.h),
   1.206 +      "Check that input data was not modified, expected: x:%i,y:%i,w:%i,h:%i, got: x:%i,y:%i,w:%i,h:%i",
   1.207 +      refRect.x, refRect.y, refRect.w, refRect.h,
   1.208        testRect.x, testRect.y, testRect.w, testRect.h);
   1.209  }
   1.210  
   1.211  /**
   1.212   * @brief Check call to SDL_SetTextInputRect
   1.213 - * 
   1.214 + *
   1.215   * @sa http://wiki.libsdl.org/moin.cgi/SDL_SetTextInputRect
   1.216   */
   1.217  int
   1.218  keyboard_setTextInputRect(void *arg)
   1.219 -{   
   1.220 +{
   1.221     SDL_Rect refRect;
   1.222 -   
   1.223 +
   1.224     /* Normal visible refRect, origin inside */
   1.225     refRect.x = SDLTest_RandomIntegerInRange(1, 50);;
   1.226     refRect.y = SDLTest_RandomIntegerInRange(1, 50);;
   1.227     refRect.w = SDLTest_RandomIntegerInRange(10, 50);
   1.228     refRect.h = SDLTest_RandomIntegerInRange(10, 50);
   1.229     _testSetTextInputRect(refRect);
   1.230 -   
   1.231 +
   1.232     /* Normal visible refRect, origin 0,0 */
   1.233     refRect.x = 0;
   1.234     refRect.y = 0;
   1.235 @@ -472,133 +472,133 @@
   1.236  
   1.237  /**
   1.238   * @brief Check call to SDL_SetTextInputRect with invalid data
   1.239 - * 
   1.240 + *
   1.241   * @sa http://wiki.libsdl.org/moin.cgi/SDL_SetTextInputRect
   1.242   */
   1.243  int
   1.244  keyboard_setTextInputRectNegative(void *arg)
   1.245 -{      
   1.246 +{
   1.247     /* Some platforms set also an error message; prepare for checking it */
   1.248 -#if SDL_VIDEO_DRIVER_WINDOWS || SDL_VIDEO_DRIVER_ANDROID || SDL_VIDEO_DRIVER_COCOA  
   1.249 +#if SDL_VIDEO_DRIVER_WINDOWS || SDL_VIDEO_DRIVER_ANDROID || SDL_VIDEO_DRIVER_COCOA
   1.250     const char *expectedError = "Parameter 'rect' is invalid";
   1.251     const char *error;
   1.252 -   
   1.253 +
   1.254     SDL_ClearError();
   1.255     SDLTest_AssertPass("Call to SDL_ClearError()");
   1.256  #endif
   1.257 -   
   1.258 +
   1.259     /* NULL refRect */
   1.260     SDL_SetTextInputRect(NULL);
   1.261     SDLTest_AssertPass("Call to SDL_SetTextInputRect(NULL)");
   1.262  
   1.263     /* Some platforms set also an error message; so check it */
   1.264 -#if SDL_VIDEO_DRIVER_WINDOWS || SDL_VIDEO_DRIVER_ANDROID || SDL_VIDEO_DRIVER_COCOA  
   1.265 +#if SDL_VIDEO_DRIVER_WINDOWS || SDL_VIDEO_DRIVER_ANDROID || SDL_VIDEO_DRIVER_COCOA
   1.266     error = SDL_GetError();
   1.267     SDLTest_AssertPass("Call to SDL_GetError()");
   1.268     SDLTest_AssertCheck(error != NULL, "Validate that error message was not NULL");
   1.269     if (error != NULL) {
   1.270 -      SDLTest_AssertCheck(SDL_strcmp(error, expectedError) == 0, 
   1.271 +      SDLTest_AssertCheck(SDL_strcmp(error, expectedError) == 0,
   1.272            "Validate error message, expected: '%s', got: '%s'", expectedError, error);
   1.273     }
   1.274  
   1.275     SDL_ClearError();
   1.276     SDLTest_AssertPass("Call to SDL_ClearError()");
   1.277  #endif
   1.278 -      
   1.279 +
   1.280     return TEST_COMPLETED;
   1.281  }
   1.282  
   1.283  /**
   1.284   * @brief Check call to SDL_GetScancodeFromKey
   1.285 - * 
   1.286 + *
   1.287   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetScancodeFromKey
   1.288   * @sa http://wiki.libsdl.org/moin.cgi/SDL_Keycode
   1.289   */
   1.290  int
   1.291  keyboard_getScancodeFromKey(void *arg)
   1.292 -{      
   1.293 +{
   1.294     SDL_Scancode scancode;
   1.295 -   
   1.296 +
   1.297     /* Regular key */
   1.298     scancode = SDL_GetScancodeFromKey(SDLK_4);
   1.299     SDLTest_AssertPass("Call to SDL_GetScancodeFromKey(SDLK_4)");
   1.300 -   SDLTest_AssertCheck(scancode == SDL_SCANCODE_4, "Validate return value from SDL_GetScancodeFromKey, expected: %i, got: %i", SDL_SCANCODE_4, scancode); 
   1.301 +   SDLTest_AssertCheck(scancode == SDL_SCANCODE_4, "Validate return value from SDL_GetScancodeFromKey, expected: %i, got: %i", SDL_SCANCODE_4, scancode);
   1.302  
   1.303     /* Virtual key */
   1.304     scancode = SDL_GetScancodeFromKey(SDLK_PLUS);
   1.305     SDLTest_AssertPass("Call to SDL_GetScancodeFromKey(SDLK_PLUS)");
   1.306 -   SDLTest_AssertCheck(scancode == 0, "Validate return value from SDL_GetScancodeFromKey, expected: 0, got: %i", scancode); 
   1.307 -        
   1.308 +   SDLTest_AssertCheck(scancode == 0, "Validate return value from SDL_GetScancodeFromKey, expected: 0, got: %i", scancode);
   1.309 +
   1.310     return TEST_COMPLETED;
   1.311  }
   1.312  
   1.313  /**
   1.314   * @brief Check call to SDL_GetScancodeFromName
   1.315 - * 
   1.316 + *
   1.317   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetScancodeFromName
   1.318   * @sa http://wiki.libsdl.org/moin.cgi/SDL_Keycode
   1.319   */
   1.320  int
   1.321  keyboard_getScancodeFromName(void *arg)
   1.322 -{      
   1.323 +{
   1.324     SDL_Scancode scancode;
   1.325  
   1.326     /* Regular key, 1 character, first name in list */
   1.327     scancode = SDL_GetScancodeFromName("A");
   1.328     SDLTest_AssertPass("Call to SDL_GetScancodeFromName('A')");
   1.329 -   SDLTest_AssertCheck(scancode == SDL_SCANCODE_A, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_A, scancode); 
   1.330 +   SDLTest_AssertCheck(scancode == SDL_SCANCODE_A, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_A, scancode);
   1.331  
   1.332     /* Regular key, 1 character */
   1.333     scancode = SDL_GetScancodeFromName("4");
   1.334     SDLTest_AssertPass("Call to SDL_GetScancodeFromName('4')");
   1.335 -   SDLTest_AssertCheck(scancode == SDL_SCANCODE_4, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_4, scancode); 
   1.336 +   SDLTest_AssertCheck(scancode == SDL_SCANCODE_4, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_4, scancode);
   1.337  
   1.338     /* Regular key, 2 characters */
   1.339     scancode = SDL_GetScancodeFromName("F1");
   1.340     SDLTest_AssertPass("Call to SDL_GetScancodeFromName('F1')");
   1.341 -   SDLTest_AssertCheck(scancode == SDL_SCANCODE_F1, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_F1, scancode); 
   1.342 +   SDLTest_AssertCheck(scancode == SDL_SCANCODE_F1, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_F1, scancode);
   1.343  
   1.344     /* Regular key, 3 characters */
   1.345     scancode = SDL_GetScancodeFromName("End");
   1.346     SDLTest_AssertPass("Call to SDL_GetScancodeFromName('End')");
   1.347 -   SDLTest_AssertCheck(scancode == SDL_SCANCODE_END, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_END, scancode); 
   1.348 +   SDLTest_AssertCheck(scancode == SDL_SCANCODE_END, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_END, scancode);
   1.349  
   1.350     /* Regular key, 4 characters */
   1.351     scancode = SDL_GetScancodeFromName("Find");
   1.352     SDLTest_AssertPass("Call to SDL_GetScancodeFromName('Find')");
   1.353 -   SDLTest_AssertCheck(scancode == SDL_SCANCODE_FIND, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_FIND, scancode); 
   1.354 +   SDLTest_AssertCheck(scancode == SDL_SCANCODE_FIND, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_FIND, scancode);
   1.355  
   1.356     /* Regular key, several characters */
   1.357     scancode = SDL_GetScancodeFromName("Backspace");
   1.358     SDLTest_AssertPass("Call to SDL_GetScancodeFromName('Backspace')");
   1.359 -   SDLTest_AssertCheck(scancode == SDL_SCANCODE_BACKSPACE, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_BACKSPACE, scancode); 
   1.360 +   SDLTest_AssertCheck(scancode == SDL_SCANCODE_BACKSPACE, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_BACKSPACE, scancode);
   1.361  
   1.362     /* Regular key, several characters with space */
   1.363     scancode = SDL_GetScancodeFromName("Keypad Enter");
   1.364     SDLTest_AssertPass("Call to SDL_GetScancodeFromName('Keypad Enter')");
   1.365 -   SDLTest_AssertCheck(scancode == SDL_SCANCODE_KP_ENTER, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_KP_ENTER, scancode); 
   1.366 +   SDLTest_AssertCheck(scancode == SDL_SCANCODE_KP_ENTER, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_KP_ENTER, scancode);
   1.367  
   1.368     /* Regular key, last name in list */
   1.369     scancode = SDL_GetScancodeFromName("Sleep");
   1.370     SDLTest_AssertPass("Call to SDL_GetScancodeFromName('Sleep')");
   1.371 -   SDLTest_AssertCheck(scancode == SDL_SCANCODE_SLEEP, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_SLEEP, scancode); 
   1.372 -   
   1.373 +   SDLTest_AssertCheck(scancode == SDL_SCANCODE_SLEEP, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_SLEEP, scancode);
   1.374 +
   1.375     return TEST_COMPLETED;
   1.376  }
   1.377  
   1.378 -/* 
   1.379 +/*
   1.380   * Local helper to check for the invalid scancode error message
   1.381   */
   1.382  void
   1.383  _checkInvalidNameError()
   1.384  {
   1.385     const char *expectedError = "Parameter 'name' is invalid";
   1.386 -   const char *error;   
   1.387 +   const char *error;
   1.388     error = SDL_GetError();
   1.389     SDLTest_AssertPass("Call to SDL_GetError()");
   1.390     SDLTest_AssertCheck(error != NULL, "Validate that error message was not NULL");
   1.391     if (error != NULL) {
   1.392 -      SDLTest_AssertCheck(SDL_strcmp(error, expectedError) == 0, 
   1.393 +      SDLTest_AssertCheck(SDL_strcmp(error, expectedError) == 0,
   1.394            "Validate error message, expected: '%s', got: '%s'", expectedError, error);
   1.395        SDL_ClearError();
   1.396        SDLTest_AssertPass("Call to SDL_ClearError()");
   1.397 @@ -607,13 +607,13 @@
   1.398  
   1.399  /**
   1.400   * @brief Check call to SDL_GetScancodeFromName with invalid data
   1.401 - * 
   1.402 + *
   1.403   * @sa http://wiki.libsdl.org/moin.cgi/SDL_GetScancodeFromName
   1.404   * @sa http://wiki.libsdl.org/moin.cgi/SDL_Keycode
   1.405   */
   1.406  int
   1.407  keyboard_getScancodeFromNameNegative(void *arg)
   1.408 -{      
   1.409 +{
   1.410     char *name;
   1.411     SDL_Scancode scancode;
   1.412  
   1.413 @@ -626,13 +626,13 @@
   1.414     SDLTest_Assert(name != NULL, "Check that random name is not NULL");
   1.415     if (name == NULL) {
   1.416        return TEST_ABORTED;
   1.417 -   }   
   1.418 +   }
   1.419     scancode = SDL_GetScancodeFromName((const char *)name);
   1.420     SDLTest_AssertPass("Call to SDL_GetScancodeFromName('%s')", name);
   1.421     SDL_free(name);
   1.422     SDLTest_AssertCheck(scancode == SDL_SCANCODE_UNKNOWN, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_UNKNOWN, scancode);
   1.423     _checkInvalidNameError();
   1.424 -         
   1.425 +
   1.426     /* Zero length string input */
   1.427     name = "";
   1.428     scancode = SDL_GetScancodeFromName((const char *)name);
   1.429 @@ -646,7 +646,7 @@
   1.430     SDLTest_AssertPass("Call to SDL_GetScancodeFromName(NULL)");
   1.431     SDLTest_AssertCheck(scancode == SDL_SCANCODE_UNKNOWN, "Validate return value from SDL_GetScancodeFromName, expected: %i, got: %i", SDL_SCANCODE_UNKNOWN, scancode);
   1.432     _checkInvalidNameError();
   1.433 -   
   1.434 +
   1.435     return TEST_COMPLETED;
   1.436  }
   1.437  
   1.438 @@ -656,58 +656,58 @@
   1.439  
   1.440  /* Keyboard test cases */
   1.441  static const SDLTest_TestCaseReference keyboardTest1 =
   1.442 -		{ (SDLTest_TestCaseFp)keyboard_getKeyboardState, "keyboard_getKeyboardState", "Check call to SDL_GetKeyboardState with and without numkeys reference", TEST_ENABLED };
   1.443 +        { (SDLTest_TestCaseFp)keyboard_getKeyboardState, "keyboard_getKeyboardState", "Check call to SDL_GetKeyboardState with and without numkeys reference", TEST_ENABLED };
   1.444  
   1.445  static const SDLTest_TestCaseReference keyboardTest2 =
   1.446 -		{ (SDLTest_TestCaseFp)keyboard_getKeyboardFocus, "keyboard_getKeyboardFocus", "Check call to SDL_GetKeyboardFocus", TEST_ENABLED };
   1.447 +        { (SDLTest_TestCaseFp)keyboard_getKeyboardFocus, "keyboard_getKeyboardFocus", "Check call to SDL_GetKeyboardFocus", TEST_ENABLED };
   1.448  
   1.449  static const SDLTest_TestCaseReference keyboardTest3 =
   1.450 -		{ (SDLTest_TestCaseFp)keyboard_getKeyFromName, "keyboard_getKeyFromName", "Check call to SDL_GetKeyFromName for known, unknown and invalid name", TEST_ENABLED };
   1.451 +        { (SDLTest_TestCaseFp)keyboard_getKeyFromName, "keyboard_getKeyFromName", "Check call to SDL_GetKeyFromName for known, unknown and invalid name", TEST_ENABLED };
   1.452  
   1.453  static const SDLTest_TestCaseReference keyboardTest4 =
   1.454 -		{ (SDLTest_TestCaseFp)keyboard_getKeyFromScancode, "keyboard_getKeyFromScancode", "Check call to SDL_GetKeyFromScancode", TEST_ENABLED };
   1.455 +        { (SDLTest_TestCaseFp)keyboard_getKeyFromScancode, "keyboard_getKeyFromScancode", "Check call to SDL_GetKeyFromScancode", TEST_ENABLED };
   1.456  
   1.457  static const SDLTest_TestCaseReference keyboardTest5 =
   1.458 -		{ (SDLTest_TestCaseFp)keyboard_getKeyName, "keyboard_getKeyName", "Check call to SDL_GetKeyName", TEST_ENABLED };
   1.459 +        { (SDLTest_TestCaseFp)keyboard_getKeyName, "keyboard_getKeyName", "Check call to SDL_GetKeyName", TEST_ENABLED };
   1.460  
   1.461  static const SDLTest_TestCaseReference keyboardTest6 =
   1.462 -		{ (SDLTest_TestCaseFp)keyboard_getSetModState, "keyboard_getSetModState", "Check call to SDL_GetModState and SDL_SetModState", TEST_ENABLED };
   1.463 +        { (SDLTest_TestCaseFp)keyboard_getSetModState, "keyboard_getSetModState", "Check call to SDL_GetModState and SDL_SetModState", TEST_ENABLED };
   1.464  
   1.465  static const SDLTest_TestCaseReference keyboardTest7 =
   1.466 -		{ (SDLTest_TestCaseFp)keyboard_startStopTextInput, "keyboard_startStopTextInput", "Check call to SDL_StartTextInput and SDL_StopTextInput", TEST_ENABLED };
   1.467 +        { (SDLTest_TestCaseFp)keyboard_startStopTextInput, "keyboard_startStopTextInput", "Check call to SDL_StartTextInput and SDL_StopTextInput", TEST_ENABLED };
   1.468  
   1.469  static const SDLTest_TestCaseReference keyboardTest8 =
   1.470 -		{ (SDLTest_TestCaseFp)keyboard_setTextInputRect, "keyboard_setTextInputRect", "Check call to SDL_SetTextInputRect", TEST_ENABLED };
   1.471 +        { (SDLTest_TestCaseFp)keyboard_setTextInputRect, "keyboard_setTextInputRect", "Check call to SDL_SetTextInputRect", TEST_ENABLED };
   1.472  
   1.473  static const SDLTest_TestCaseReference keyboardTest9 =
   1.474 -		{ (SDLTest_TestCaseFp)keyboard_setTextInputRectNegative, "keyboard_setTextInputRectNegative", "Check call to SDL_SetTextInputRect with invalid data", TEST_ENABLED };
   1.475 +        { (SDLTest_TestCaseFp)keyboard_setTextInputRectNegative, "keyboard_setTextInputRectNegative", "Check call to SDL_SetTextInputRect with invalid data", TEST_ENABLED };
   1.476  
   1.477  static const SDLTest_TestCaseReference keyboardTest10 =
   1.478 -		{ (SDLTest_TestCaseFp)keyboard_getScancodeFromKey, "keyboard_getScancodeFromKey", "Check call to SDL_GetScancodeFromKey", TEST_ENABLED };
   1.479 +        { (SDLTest_TestCaseFp)keyboard_getScancodeFromKey, "keyboard_getScancodeFromKey", "Check call to SDL_GetScancodeFromKey", TEST_ENABLED };
   1.480  
   1.481  static const SDLTest_TestCaseReference keyboardTest11 =
   1.482 -		{ (SDLTest_TestCaseFp)keyboard_getScancodeFromName, "keyboard_getScancodeFromName", "Check call to SDL_GetScancodeFromName", TEST_ENABLED };
   1.483 +        { (SDLTest_TestCaseFp)keyboard_getScancodeFromName, "keyboard_getScancodeFromName", "Check call to SDL_GetScancodeFromName", TEST_ENABLED };
   1.484  
   1.485  static const SDLTest_TestCaseReference keyboardTest12 =
   1.486 -		{ (SDLTest_TestCaseFp)keyboard_getScancodeFromNameNegative, "keyboard_getScancodeFromNameNegative", "Check call to SDL_GetScancodeFromName with invalid data", TEST_ENABLED };
   1.487 +        { (SDLTest_TestCaseFp)keyboard_getScancodeFromNameNegative, "keyboard_getScancodeFromNameNegative", "Check call to SDL_GetScancodeFromName with invalid data", TEST_ENABLED };
   1.488  
   1.489  static const SDLTest_TestCaseReference keyboardTest13 =
   1.490 -		{ (SDLTest_TestCaseFp)keyboard_getKeyNameNegative, "keyboard_getKeyNameNegative", "Check call to SDL_GetKeyName with invalid data", TEST_ENABLED };
   1.491 +        { (SDLTest_TestCaseFp)keyboard_getKeyNameNegative, "keyboard_getKeyNameNegative", "Check call to SDL_GetKeyName with invalid data", TEST_ENABLED };
   1.492  
   1.493  static const SDLTest_TestCaseReference keyboardTest14 =
   1.494 -		{ (SDLTest_TestCaseFp)keyboard_getScancodeNameNegative, "keyboard_getScancodeNameNegative", "Check call to SDL_GetScancodeName with invalid data", TEST_ENABLED };
   1.495 +        { (SDLTest_TestCaseFp)keyboard_getScancodeNameNegative, "keyboard_getScancodeNameNegative", "Check call to SDL_GetScancodeName with invalid data", TEST_ENABLED };
   1.496  
   1.497  /* Sequence of Keyboard test cases */
   1.498  static const SDLTest_TestCaseReference *keyboardTests[] =  {
   1.499 -	&keyboardTest1, &keyboardTest2, &keyboardTest3, &keyboardTest4, &keyboardTest5, &keyboardTest6, 
   1.500 -	&keyboardTest7, &keyboardTest8, &keyboardTest9, &keyboardTest10, &keyboardTest11, &keyboardTest12, 
   1.501 -	&keyboardTest13, &keyboardTest14, NULL
   1.502 +    &keyboardTest1, &keyboardTest2, &keyboardTest3, &keyboardTest4, &keyboardTest5, &keyboardTest6,
   1.503 +    &keyboardTest7, &keyboardTest8, &keyboardTest9, &keyboardTest10, &keyboardTest11, &keyboardTest12,
   1.504 +    &keyboardTest13, &keyboardTest14, NULL
   1.505  };
   1.506  
   1.507  /* Keyboard test suite (global) */
   1.508  SDLTest_TestSuiteReference keyboardTestSuite = {
   1.509 -	"Keyboard",
   1.510 -	NULL,
   1.511 -	keyboardTests,
   1.512 -	NULL
   1.513 +    "Keyboard",
   1.514 +    NULL,
   1.515 +    keyboardTests,
   1.516 +    NULL
   1.517  };