Java unit testing

Recently we started writing unit test in school. A unit test is a program that tests your main program if it works properly. Of course we can test them with the console, but with unit tests it’s faster and more accurate. We are using JUnit for it. JUnit is a simple framework to write repeatable tests. It is an instance of the xUnit architecture for unit testing frameworks.
We were testing the program ManyToOne, where we should make objects and make this objects linkable. There are 2 main types of objects – Many and One. The Many type objects should be able to link to only one One object at a time and the One type of object should have many Many objects related to it.

Here are the links to the ManyToOneRelation class and ManyToOneRelationTest:

If you have any questions to unit testing in java or something else related to programing, feel free to contact me!


First exam

For our first exam we needed to make a program on any language that we want, which was ment to read a csv file and write to an other one. It sounds easy, but less than 10 students have done it. Maybe it’s because the time was very limited or maybe we were just not prepared for this. However no one from the 6 people that did it used java. This may be because java is a good OO language and for such sort task you need to write a lot lines just to make the code works properly, while the whole code on ruby is less than 10 lines.

Here’s the link to the task using ruby:

Here’s the link to the task using java: 

Entry programs for 11 grade in TUES

This are our tasks

We need to accomplish all of them in less than 1 week time using any programming language we know. I prefered and used C, because I have learned it the whole past year.

At the following link you can see all the programs :