1 / 18

Exploiting Automatic Testing in BlueJ Programming Process and Practical Lab Exam

Exploiting Automatic Testing in BlueJ Programming Process and Practical Lab Exam. Michael E. Caspersen University of Aarhus Denmark mec@daimi.au.dk. User Talk First BlueJ Day, 1 March 2006. Uses of BlueJ. General IDE edit, compile, run, ... Exploring “the notional machine”

Download Presentation

Exploiting Automatic Testing in BlueJ Programming Process and Practical Lab Exam

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Exploiting Automatic Testingin BlueJProgramming Process and Practical Lab Exam Michael E. Caspersen University of Aarhus Denmark mec@daimi.au.dk User Talk First BlueJ Day, 1 March 2006

  2. Uses of BlueJ • General IDE • edit, compile, run, ... • Exploring “the notional machine” • debugger (flow of control, object model, object interaction, ...) • Incremental program development • automatic testing • Model-driven programming • UML support First BlueJ Day, 1 March 2006

  3. Outline • Programming Process • Choice of Examination Form • Practical Lab-Exam • ”Conclusion” First BlueJ Day, 1 March 2006

  4. Programming Process

  5. The Missing Link... tools concepts language constructs finished programs ? First BlueJ Day, 1 March 2006

  6. tools concepts language constructs finished programs Strategies, Principles, and Techniques ... for the systematic development of programs • The Practice of Programming • Describe strategies, principles, and techniques of program development • Demonstrate how to apply these in action • Develop programs instead of simply showcasing them • Demonstrate that programming is a non-linear process • Demonstrate incremental development • Demonstrate model-driven development • Demonstrate test-driven development • Demonstrate responsibility-driven development • Demonstrate refactoring • Demonstrate how to find and handle errors • Demonstrate how to use online documentation • Demonstrate, demonstrate, demonstrate ... First BlueJ Day, 1 March 2006

  7. public class Date { private int d, // 1 <= d <= daysInMonth m, // 1 <= m <= 12 y; public Date(int dd, int mm, int yy) { d = dd; m = mm; y = yy; } public void setToNextDate() { d = d + 1; } public String toString() { return d + "-" + m + "-" + y; } } Example: Class Date • Refinement of class Date • Special cases • systematic treatment of special cases • suppress implementation details • introduce private methods to handle special cases • The mañana principle • introduce an abstraction • worry about implementation details ”tomorrow” First BlueJ Day, 1 March 2006

  8. Refinement and Automatic Testing R1: Naive implementation of class Date R2: Add checkDayOverflow R3: Add checkMonthOverflow R4: 28, 30, or 31 days in month R5: Partial leap year rule R6: Complete leap year rule First BlueJ Day, 1 March 2006

  9. Choice of Examination Form

  10. Education as a Goal-Oriented Activity • Articulate aims and goals • Short as well as long term • Micro as well as macro level (assignment, lecture, course, degree) • Design assessment method • such that a winning strategy with respect to assessment optimize learning • Design teaching and (intended) learning process • Progression, abstract vs. concrete, general vs. special, apprenticeship approach, spiral approach, early bird, ... • Decide on dissemination methods • Material (textbook, web, learning objects, videos, sample programs, ...) • Teaching method (lecture, class, lab, student collaboration, project work, supervision, ...) First BlueJ Day, 1 March 2006

  11. Course and Exam Must Match • The final exam must reflect the contents of the course • The spirit and style of student assessment defines de facto the curriculum.— Rowntree, 1977 • The type of grading influences the student’s learning approach. — Ramsden, 1992 • We find it mandatory to apply an evaluation form where the students demonstrate their practical programming skills as well as their understanding of the fundamental concepts and theories from the curriculum of the course. • In short: course contents and final exam must match. First BlueJ Day, 1 March 2006

  12. Oral Exam Written Exam Multiple Choice Practical Exam Choice of Examination Form • Test the students against expected competencies • After the course the student will be able to use fundamental elements in a modern programming language • Use conceptual modelling for systematic development of simple object-oriented programs • Implement simple oo-models in a modern programming language, and • Use selected class libraries • Weekly mandatory assignments prepare the students for the exam but they don’t count in the final grading First BlueJ Day, 1 March 2006

  13. Practical Lab Exam

  14. Practical Lab Exam • Staff • Teacher, external examiner, 4-5 TAs • Students • 20 per group; 12 groups (200+ students) • Time • 30 minutes for the assignment, 60 minutes in total • Assignment • A new for each group (though similar) • ~10 programming tasks; breakpoint after #2 • Pass point: task #6 • Evaluation • Process as well as product (i.e. the students behaviour also counts in the final grading • If the lecturer and external examiner estimate so, an appropriate and systematic programming process can compensate for minor flaws and errors in the product and make a student pass First BlueJ Day, 1 March 2006

  15. Employee String name int salary int getSalary() String toString() 1 * hOD employees Department String departmentName void add(Employee e) void remove(Employee e) Employee getHOD() int getDepartmentSalary() Employee bestPaidEmployee () Sample Exam Assignment • Create a simple class Employee with constructor, getSalary, and toString method… • Create a class EmployeeTest... • Create a new class Department ... • Implement the methods addTrack, removeTrack, and getHOD • Create a class DepartmentTest… • Implement getDepartmentSalary • Add a method to DepartmentTest to test the getDepartmentSalary method • Implement bestPaidEmployee • Add a method to DepartmentTest to test the bestPaidEmployee method • Let the Employee class implement the Comparable interface… First BlueJ Day, 1 March 2006

  16. Use of BlueJ • Develop • Test • Submit First BlueJ Day, 1 March 2006

  17. “Conclusion” • General IDE • edit, compile, run, ... • Exploring “the notional machine” • debugger • Incremental program development • automatic testing • Model-driven programming • UML support BlueJ Simplifies Matters First BlueJ Day, 1 March 2006

  18. References Jens Bennedsen & Michael E. Caspersen,”Programming in Context – A Model-First Approach to CS1”, Proceedings of the thirty-fifth SIGCSE Technical Symposium on Computer Science Education, Norfolk, Virginia, USA, 2004, pp. 477-481. Jens Bennedsen & Michael E. Caspersen,”Teaching Object-Oriented Programming – Towards Teaching a Systematic Programming Process”, Proceedings of the Eighth Workshop on Pedagogies and Tools for the Teaching and Learning of Object-Oriented Concepts, 18th European Conference on Object-Oriented Programming, ECOOP 2004, Oslo, Norway, 2004. Jens Bennedsen & Michael E. Caspersen,”Revealing the Programming Process”, Proceedings of the thirty-sixth SIGCSE Technical Symposium on Computer Science Education, St. Louis, Missouri, USA, 2005, pp. 186-190. Jens Bennedsen & Michael E. Caspersen,”Assessing Process and Product – A Practical Lab Exam for an Introductory Programming Course”, Submitted for Frontiers in Education, FIE 2006, San Diego, USA, October 2006. Michael E. Caspersen, Teaching Object-Oriented Programming – Strategies, Principles, and Techniques, Progress Report, Department of Computer Science, University of Aarhus, 18 April 2005. (42 pages) www.daimi.au.dk/~mec/papers/ mec@daimi.au.dk First BlueJ Day, 1 March 2006

More Related