Regressiotestaus- ja ylläpitotyökalu Ohjelmoinnin perusteet -kurssin Python-harjoitustehtäville


Autoria(s): Arola, Ville
Data(s)

18/04/2013

18/04/2013

2011

Resumo

Tässä kandidaatintyössä suunnitellaan ja toteutetaan regressiotestaus- ja ylläpitotyökalu Ohjelmoinnin perusteet -kurssin Python-ohjelmointitehtäville. Työkalun on tarkoitus auttaa kurssin vastuuhenkilöitä selvittämään kurssilla käytettyjen harjoitustehtävien esimerkkiratkaisujen toimivuus Python-versiossa, jota kurssilla aiotaan käyttää ohjelmointiympäristönä seuraavana vuonna, ja helpottaa harjoitusmateriaalin yhdenmukaisuuden varmistamista silloin kun Python-versiota vaihdetaan tai materiaaliin tehdään muutoksia. Työssä tutkitaan, miten tarkoitukseen sopiva yleispätevä testaustyökalu voidaan kehittää, mitä seikkoja sen suunnittelussa on otettava huomioon ja mitä ongelmia kehittämiseen liittyy. Yleispätevän testaustyökalun kehittäminen osoittautui hankalaksi, vaikka testattavat ohjelmat ovat yksinkertaisia. Harjoitusmateriaaliin kuuluneiden yli 50 ohjelman testaamisessa tarvittavia tiedostoja oli yhteensä hyvin suuri määrä, ja niiden käsittelemiseksi työkalussa ja sen ulkopuolella oli vaikeaa valita optimaalista hakemistorakennetta. Lisäksi joidenkin testattavien ohjelmien havaittiin vaativan testauksessa muista poikkeavia lisätoimenpiteitä, jotka päätettiin jättää toteuttamatta työn puitteissa. Työn toivottu tulos jäi siten osittain saavuttamatta. Tuloksena syntyi kuitenkin työkalu, jolla voidaan ajaa 93 % nykyisistä esimerkkiratkaisuista määritellyillä testisyötteillä halutussa Python -ympäristössä ja saada tiedot ohjelmien toimivuudesta sekä niiden tuottamien tulosteiden täsmäävyydestä esimerkkitulosteisiin.

In this Bachelor’s thesis, a regression testing and maintenance tool for the Python programming exercises of Fundamentals of Programming course will be designed and implemented. The tool is intended to help the administrative personnel of the course to determine whether the existing solutions to the course’s exercise tasks work in a Python version that is considered to be used as the programming environment during the course in the following year. The tool also aims to make it easier to keep the exercise material coherent when Python version or the exercise material is changed. In this thesis, the methods for implementing a general testing tool suitable for the described purpose are studied along with things that need to be taken into consideration and problems which are present in the development of the tool. The development of a general testing tool proved difficult even though the tested programs were simple. The number of files needed in order to test the over 50 programs in the exercise material was very large, and choosing an optimal directory structure to manage them within and outside the tool was difficult. In addition, some of the programs were found to require additional measures in the tool’s design in order to test them properly, and were decided not to be implemented within the scope of the thesis. Therefore, not all objectives of this thesis were entirely met. None the less, a tool was devised which enables 93 % of the programs in the current set of exercise solutions to be run automatically with given test inputs in a preferred Python environment, and the resulting information to be obtained about their functionality in the chosen environment and coherence of the example outputs.

Identificador

http://www.doria.fi/handle/10024/90058

URN:NBN:fi-fe201304112720

Idioma(s)

fi

Palavras-Chave #Regressiotestaustyökalu #automatisoitu testaus #Python #Regression testing tool #automated testing
Tipo

Bachelor's thesis

Kandityö