Skip to content

UItesting

aadityayadav17 edited this page Oct 17, 2023 · 3 revisions

UI-Testing

Creating unit tests for UI elements is inefficient as most of them do not have many functions to mock. Most of these elements display objects using tables and AddComponent methods.

So to overcome this we approach manual testing of such elements. This involves going through each and every task in the code to ensure that the elements are working as intended.

Some of the general guidelines we followed to ensure testing are:

  • Images do not stretch beyond the screen size.
  • Images that fill up spaces are not stretched so much that they lose clarity(eg. backgrounds), or in other words, ensure image resolution is appropriate for the case.
  • Buttons should not overlap each other.
  • Buttons should do what they are actually intended for.
  • Images and buttons show up at the intended places.
  • Ensuring additions to the game do not ruin visual aesthetics.
  • Maintaining a similar theme across all elements used.

These general guidelines helped us verify that everything was working as intended.

UI-Screens

Making these guidelines the standard we got the following result for each external UI screen:

MainMenuScreen

image

  • Background appears in place.
  • Sprites of celestial bodies appear in place.
  • Background & sprite remain in sync even after resolution change and minimising and maximising.
  • Buttons appear in place and work as intended.

LevelSelectScreen

image

  • Background appears in place.
  • Sprites of planets (levels) appear in place.
  • Background & sprite remain in sync even after resolution change and minimising and maximising.
  • Unlocked planets are clikable.
  • Planet description & borders comes up when mouse is hovered over them.
  • To verify level lock mechanism, win & lose conditions were modified in MainGameScreen, to trigger one of these conditions, and therefore trigger one of WinningScreen, NextLevelScreen and LoosingScreen, as soon as the level was clicked. This also proved to be a time effective approach.

SettingsScreen

image

  • Background appears in place.
  • Background remain in sync even after resolution change and minimising and maximising.
  • Buttons appear in place and work as intended.

WinScreen(level)

image

  • Background image shows up as intended
  • Buttons placement is correct and works properly

WinScreen(Overall)

image

  • Background image shows up as intended
  • Buttons placement is correct and works properly

LooseScreen

image

  • Background image show up as intended
  • Buttons placement is correct and works properly

LoadingScreen

image

  • Text animation shows as intended.
  • Background image is in place.

StoryScreen

image

  • All images show up as intended.
  • Text on each image shows up in place.
  • Buttons(Continue, Skip) appear in place and work as intended.

HelpScreen:

GameDescriptionScreen

image

  • Game intro description text appears in place.
  • All four images of engineers, Towers, Aliens and currency appear in place.
  • Text accompanying the images appears in place.
  • All 4 buttons (Tutorial, Back, Mobs, HowToPlay) Appear in place and work as intended.
  • Background appears in place.

Tutorial

image

  • Game component descriptions appear in place.
  • All Buttons(Continue, Continue, Back) appear in place and work as intended.
  • Towers can be placed when the mobs are paused as intended.
  • Elements match the main game as intended.

HowToPlay

image

  • Game component description image appears in place.
  • Background appears in place.
  • Buttons (up, back) appear in place and work as intended.

MobsDescription

image

  • Background appears in place.
  • Images of Mobs appear in place.
  • Text accompanying each mobimage appears in place.
  • Buttons(Left, Back, Tower, BossMob) appear in place and work as intended.

BossMobDescription

image

  • Background appears in place.
  • Images of BossMobs appear in place.
  • Text accompanying each image appears in place.
  • Buttons(Up, Back) appear in place and work as intended.

TowerDescription

image

  • Background appears in place.
  • Images of Towers appear in place.
  • Text accompanying each image appears in place.
  • Buttons(left, Back) appear in place and work as intended.
Clone this wiki locally