CS499 Project #3 XML mySQL Test Generation Members Erica Wade Kevin Hardison Sameer Patwa Yi Lu
Design Overview Working with existing data (via parser) Database format and structure Data manipulation (via user interface) Test output (via user interface)
Parser Input – Test Question
A Tokenized Question
Parser Output - SQL
ENTITY RELATIONSHIP DIAGRAM AND RELATIONAL SCHEMA
ENTITY RELATIONSHIP DIAGRAM Questions From Books Answers To Label Body Correct Edition Title BookID Author Chapter Category Type Body QuestionID
ENTITY RELATIONSHIP DIAGRAM ENTITIES (Tables) Questions Books Answers ATTRIBUTES Questions – QuestionID, body, type, category, chapter. Books – BookID, Title, Author, Edition. Answers – Body, label, correct.
ENTITY RELATIONSHIP DIAGRAM CONSTRAINTS Participation Constraints: Each question is associated with at least 0 books. Each answer is associated with at least one question. Key Constraints: One book can have many questions. Each question must have one answer. Weak Entity Set: Answers are identified only by association with questions
RELATIONAL SCHEMA Some of the SQL statements that we have in our projects Here is an SQL statement for creating a table for books: CREATE TABLE Questions( QuestionID INTEGER, Body TEXT, Type CHAR(20), Category CHAR(15), Chapter INTEGER, PRIMARY KEY (QuestionID), FOREIGN KEY (BookID) REFERENCES Books));
RELATIONAL SCHEMA Here is an SQL statement for inserting data into the Books table: INSERT INTO books (BookID, Title, Author, Edition) VALUES ('1', "Discover computers", “Sameer Patwa", '2');
RELATIONAL SCHEMA SQL statement for updating data in the Books table: This will modify a column's value in existing row of a table. UPDATE books SET Title = ‘Discover Computers’ WHERE Author = ‘John Doe’;
RELATIONAL SCHEMA SQL SELECT statement for running queries: SELECT * FROM Questions; SELECT Answers.Correct, Questions.body FROM Answers, Questions WHERE Questions.QuestionID=Answers.QuestionID;
GRAPHIC USER INTERFACE (GUI)
TEST GENERATION
Conclusion… Where we are, and what’s next? Begin the next revolution of spiral process Show the customer what we have & get feedback Test and finalize parser…adapt if necessary Gather any other existing data Implement the user interface