Skip to main content Skip to local navigation
Home » Posts tagged 'unit test'

unit test

Unit testing for a project in Java

It’s important to create test frameworks for your programs. In Java we use the jUnit system to do so. Here is an example of setting up a unit tester to make sure that that a method returns the values it’s supposed to. First, let’s look at the method. I’m using it to convert values that […]

Automated Grading of Python in VPL using Unit Tests

A few of my colleagues here at YorkU have expressed an interest in using Python with Virtual Programming Lab on our Moodle-based eClass Learning Management System. I don’t have a lot of Python experience, having only really used it for some data processing and toy embedded system demonstrations in the past. So I adapted the […]

ChatGPT: “I’m sorry but I couldn’t find any information”

While chatbots like ChatGPT are truly ground-breaking, they have limitations. In fact, there are many cases in which chatbots simply cannot return an answer due to the limitations of the LLM structure and dataset. Experts quickly find the limitations of chatbots, but novices to a topic are very likely to get tripped up by the […]

Unit Testing a Question Bank

I’m working on question sets for introductory programming classes in languages like Java, C and Matlab, with a possibility of extending into other commonly-used languages (in our department) like Python and Verilog. The idea is that these questions could be deployed into a protected lab test or an open in-class “flipped homework” environment. Key to […]

Automated Student Evaluations in C (part 5)

This is the fifth in the series of postings on automated grading in C. Here, I’ve modified the VPL exercise to include four possible flowcharts that the students can implement, but the particular flowchart now get assigned to the student based on the time of day. The VPL output (both “run” and “evaluate” looks like […]

Ad-hoc unit testing on simAVR and VPL

In the previous post I showed you how to use VPL and simAVR together to write a basic activity that would test to see if a student could change or assign the value of a register in the simulated microcontroller using the C programming language. While it was the most straight-forward way that I could […]