Information Technology Topic
Testing a Website
- Read notes
- Flashcards
- Quiz
- Confident
Study focus - 3 things
- Testing means opening the site in a web browser the way a visitor would, on more than one browser and device, before it is published
- Verify every hyperlink and every picture on every page, and fix and retest anything that fails
- Use a test audience of people who did not build the site, give them tasks and watch, because you are not your users
Section 1Why a website is tested
A website that has not been tested will have mistakes in it, and the visitors will find them. A link that goes nowhere, a missing picture or a page that is hard to read on a phone makes the whole site look careless. Here's the trick: test small parts as you go, not everything at the very end. Mistakes found late cost more to fix than mistakes found early. The other big idea is that you are not your users. You built the site, so you know where everything is and you read your own words the way you meant them. Real visitors do not. That is why testing includes people outside the team who built the site.
Section 2Testing in a web browser
The first test is simple: open the site in a web browser, the program visitors will use, and go through it as a visitor would. Do not rely only on the preview inside your web-design package. Look at each page. Does the text read well? Do the pictures show? Does the layout hold together? Then try more than one browser, because the same page can look different from one browser to the next. Also try phones and tablets, and use real devices where you can, since many visitors will arrive on a phone. Two extra tests check that visitors with disabilities can use the site. Try to use the site with the keyboard only (no mouse), and try it with a screen reader, which reads the page aloud. If you cannot reach a link from the keyboard, some visitors cannot either.
Section 3Verifying every hyperlink
A link that does not lead where it should is called a broken link. Check every one, on every page: click it and see that it opens the right place. A page link should open the right page. A link to a spot should land on the right heading. An email link should open a new message addressed to the right person. A link to a file should open it or offer a download. A picture should actually appear, and every page should have a way back to the home page. Broken links usually have simple causes: a file name spelt differently in the link and in the folder, a wrong folder path (such as a missing ../), a file that was renamed or deleted, or a spot name that does not match. A link to another website can also break later if the other site moves or removes the page, so check those again from time to time. Watch out: checking only the home page is not enough. Every page has its own links and pictures. A simple checklist helps: page, item, did it work, tick.
Section 4Using a test audience
A test audience is a group of people from outside the team who built the site: classmates, friends and family, colleagues. They tell you what you cannot see for yourself. The best method is usability testing. You give each volunteer a few specific tasks, such as finding the opening hours or sending an order by email, and you watch them try. You ask them to say aloud what they are thinking as they go. This shows you unclear wording, confusing layout and ideas for improvement. A session usually lasts 30 to 60 minutes. Before the real sessions, try the tasks out with a colleague first, so you can fix any problems with the tasks themselves. Easy to mix up: you are there to watch and listen, not to help. If you point out where to click, you learn nothing about whether the site works. Step in only if a volunteer is completely stuck, and then just to get them going again.
Section 5Recording problems, fixing and retesting
Write down every problem as it turns up: which page, what went wrong, and what you did about it. A short test log keeps the work organised and tells you when you are done. After fixing something, test it again. Then check the other things that could be affected. A renamed file, for example, can break every link that pointed to the old name. Watch out: a fix can create a new problem. Retesting the whole page, and not just the one item you fixed, catches this.
Section 6Counting what has to be tested
Testing is partly arithmetic, and the numbers add up faster than people expect. Suppose a site has 6 pages and you want to see each page in 3 browsers on a computer, plus a phone and a tablet. That is 6 x (3 + 2) = 30 page views. Links work the same way. If a page has 6 links and 3 pictures, there are 6 + 3 = 9 items to check on that page. Add up every page and you have the full list. Test audience time adds up too: 5 volunteers at 30 minutes each is 5 x 30 = 150 minutes, which is 2 hours 30 minutes, before you count any practice session with a colleague. Plan the time before you promise a date.
Examples
A Falmouth tour guide has a four-page site. The files are index.html, tours.html, gallery.html, contact.html, images/harbour.jpg, images/guide.jpg and files/tour-prices.pdf. The pages hold these items. index.html: links to tours.html, gallery.html, contact.html and tour.html, and the picture images/harbour.jpg. tours.html: links to index.html, files/tour-prices.pdf, contact.html, files/tour-price.pdf and https://www.example.org/ferry-times, and the picture images/guide.jpg (the page has a spot named prices). gallery.html: links to index.html, tours.html#prices and tours.html#price, and the pictures images/harbour.jpg and images/harbor.jpg. contact.html: links to ../index.html, tours.html and mailto:info@falmouthtours.example. (a) How many links and pictures are there altogether? (b) How many can be checked against the file list, and how many must be tried by hand? (c) Find the broken ones and give the cause of each. (d) The three mistyped file names are fixed. How many problems remain?
(a) Links: 4 + 5 + 3 + 3 = 15. Pictures: 1 + 1 + 2 + 0 = 4. Altogether 19 items. (b) The link to the other website and the email link cannot be checked against your own files. They must be clicked by hand to see that the other site still answers and that a new message opens. That is 2 by hand and 19 - 2 = 17 checked against the file list. (c) Five are broken. tour.html is a typing slip because the file is tours.html. files/tour-price.pdf is another slip because the file is tour-prices.pdf. tours.html#price names a spot that does not exist (it is prices). images/harbor.jpg is spelt differently from harbour.jpg. ../index.html on contact.html climbs above the site's top folder because contact.html is already in the top folder; the right link is index.html. (A live site may sometimes shrug this off, but it fails when you test from the site folder on your own computer, and it is wrong either way.) So 17 - 5 = 12 work. (d) Fixing tour.html, files/tour-price.pdf and images/harbor.jpg leaves the spot name price and the ../index.html path, so 2 remain. Retest both pages after the fixes. Watch out: if you only checked the home page you would have found 1 of the 5.
A Negril café site has 6 pages. The owner's daughter plans the testing. Each page will be viewed in 3 browsers on a computer, on 1 phone and on 1 tablet. She will also hold a usability test with 5 volunteers from her class, 30 minutes each, after a 30-minute practice session with her teacher. In the real sessions, 4 of the 5 volunteers could not find the opening hours. (a) How many page views is that? (b) How much time do the usability sessions take, with and without the practice session? (c) What share of the volunteers could not find the opening hours, and what should she do? (d) Explain why she should not ask her family who helped build the site to be the only testers.
(a) 6 pages x (3 browsers + 1 phone + 1 tablet) = 6 x 5 = 30 page views. (b) The real sessions take 5 x 30 = 150 minutes, which is 2 hours 30 minutes. With the 30-minute practice session it is 180 minutes, exactly 3 hours. (c) 4 out of 5 is 80%. A problem that most of the audience hits is a design problem, not their fault, so she should make the opening hours easier to find (for example, put them on the home page or add a clear link) and test again. (d) People who helped build the site know where everything is, so they will not trip over the things new visitors do. You are not your users. A test audience from outside the team shows how the site works for people who have never seen it.
Now let's water it
Session runs notes to flashcards to quiz back-to-back.
Where this comes from
- CSEC Information Technology Syllabus (CXC 30/G/SYLL 08, revised 2000, 2008, 2013) · Caribbean Examinations Council (CXC) · Section 6, Specific Objective 27 · Syllabus scope
- MDN Web Docs: Learn web development (various pages) · Mozilla and MDN contributors · Page introduction-to-cross-browser-testing, MDN Introduction to cross browser testing, checked against (https://developer.mozilla.org/en-US/docs/Learn_web_development/Extensions/Testing/Introduction) · Facts
- GOV.UK Service Manual: user research guidance · UK Government Digital Service (GOV.UK) · Page using-moderated-usability-testing, GOV.UK Using moderated usability testing, checked against (https://www.gov.uk/service-manual/user-research/using-moderated-usability-testing) · Facts
- GOV.UK Service Manual: user research guidance · UK Government Digital Service (GOV.UK) · Page start-by-learning-user-needs, GOV.UK Start by learning user needs, checked against (https://www.gov.uk/service-manual/user-research/start-by-learning-user-needs) · Facts