Skip to content

Commit

Permalink
Manual Test Sensei is born
Browse files Browse the repository at this point in the history
  • Loading branch information
mantertius committed Mar 29, 2023
1 parent cc4e171 commit fd88504
Show file tree
Hide file tree
Showing 44 changed files with 19,643 additions and 1,888 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,5 @@
*.htm
testcases/page.htm
testcases/results.csv
*.csv
manual_test_smells.egg-info
testcases/file.log
File renamed without changes.
File renamed without changes.
33 changes: 33 additions & 0 deletions ManualTestSensei/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Creating a venv
We advise the creation of a virtual enviroment. Run this:
`python -m venv venv`
Then, activate the venv.

on linux:
`source ./venv/bin/activate`

on windows:

`.\venv\Scripts\`

Now, you must install the dependencies.

# Installing
To run the program, you must install some packages. Run this:

`pip install -r requirements.txt`

After downloading everything, you must download spacy's model.

`python -m spacy download en_core_web_trf`

After this, you are done.

# Running
To run the program, simply call it using the python runner and follow the instructions:

`python main.py english`

# After running
After the program has ended, a .csv file will be created. It will always be named following this format:
`result-date-time-model.csv`
File renamed without changes.
File renamed without changes.
14 changes: 7 additions & 7 deletions testcases/data.py → ManualTestSensei/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,13 @@ def smells_loader(smell_acronym: str) -> pd.DataFrame:
return smells_loader


def smells_loader_closure_v2():
df = pd.read_csv('dirs.txt', header=None)
df.columns = [FILE_COL]
df = df.loc[df[FILE_COL].apply(lambda x: Path(x).exists())]
df[FILE_COL] = df[FILE_COL].apply(lambda x: Path(x))
print(df)
return df.reset_index(drop=True)
# def smells_loader_closure_v2():
# df = pd.read_csv('dirs.txt', header=None)
# df.columns = [FILE_COL]
# df = df.loc[df[FILE_COL].apply(lambda x: Path(x).exists())]
# df[FILE_COL] = df[FILE_COL].apply(lambda x: Path(x))
# print(df)
# return df.reset_index(drop=True)


smells_loader = smells_loader_closure()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from testcases.keywords import Keywords
from keywords import Keywords

adverbs_of_manner_termination = Keywords().keywords['adverbs_of_manner_termination']

Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from testcases.keywords import Keywords
from keywords import Keywords

verifications = Keywords().keywords['verifications']

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from testcases.keywords import Keywords
from keywords import Keywords

verifications = Keywords().keywords['verifications']

Expand Down
File renamed without changes.
2 changes: 2 additions & 0 deletions testcases/dir_finder.py → ManualTestSensei/dir_finder.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
# This is an auxiliary tool to identify all the files on the repo.

import glob
from rich import print
import os
Expand Down
File renamed without changes.
11,975 changes: 11,975 additions & 0 deletions ManualTestSensei/file.log

Large diffs are not rendered by default.

305 changes: 305 additions & 0 deletions ManualTestSensei/files.csv

Large diffs are not rendered by default.

File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion testcases/main.py → ManualTestSensei/main.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import logging.config

from data import get_tests
from testcases import matchers
import matchers

logging.config.fileConfig(fname='log.config', disable_existing_loggers=False)
log = logging.getLogger(__name__)
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ smart-open==5.2.1
# via
# pathy
# spacy
spacy==3.5
spacy==3.4.1
# via manual-test-smells (setup.py)
spacy-legacy==3.0.12
# via spacy
Expand Down
7,299 changes: 7,299 additions & 0 deletions ManualTestSensei/results-20230329-125316-en_core_web_lg.csv

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion testcases/setup.py → ManualTestSensei/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
name='manual_test_smells',
version='0.0.2',
packages=find_packages(),
install_requires=['spacy==3.5',
install_requires=['spacy==3.4.1',
'pandas',
'rich',
'scipy',
Expand Down
File renamed without changes.
File renamed without changes.
19 changes: 16 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
# Ubuntu Manual Test Smell Analysis
This repository contains the manual testcases utilized by the quality team for testing ubuntu (and its flavors) packages and images, as well as manual tests for hardware compatibility.
# Manual Test Sensei 🥷
Manual Test Sensei is a tool for detecting "test smells" in manual testing. Test smells are patterns of poor testing practices that can lead to ineffective or incomplete testing. By identifying and addressing these issues, Manual Test Sensei can help improve the quality and effectiveness of manual testing.

The smells identified by our Sensei are based on the paper [Hunting for smells in natural language tests](https://ieeexplore.ieee.org/document/6606682/), by _Hauptmann et al._, on the [Open Test Smells Catalog](https://easy.github.io/testsmells/index.html), and on the tool creators' expertise on the subject.

Also, there is a written paper associated

This repository is divided in two main folders. `\ManualTestSensei\` which is our tool, `\testcases\` where the UbuntuOS testcases are located.

## `\ManualTestSensei\`

This folder contains the tool and it's packages. There's a `README.md` inside it, guiding the reader on how to use the tool. If you want to run the tool, enter this folder.

## `\testcases\`
This folder contains the manual testcases utilized by the quality team for testing ubuntu (and its flavors) packages and images, as well as manual tests for hardware compatibility. It's a fork of [Ubuntu Manual Tests](https://launchpad.net/ubuntu-manual-tests) that has been analyzed in search of test smells. If you want to see how a manual test is written, enter this folder.


Also, this is a fork of [Ubuntu Manual Tests](https://launchpad.net/ubuntu-manual-tests) that has been analyzed in search of test smells. These smells are based on Hauptmann et al. and on the [Open Test Smells Catalog](https://easy.github.io/testsmells/index.html).


Loading

0 comments on commit fd88504

Please sign in to comment.