Have you ever get confused when trying TestNG for the first time? especially when want to make a unit test with some execution order? I have :). So, I made a little example to encounter those problem. As we know, TestNG has some annotation to point our method/class and indicate when the test will running. Some of which are :
- @BeforeSuite: The annotated method will be run before all tests in this suite have run.
- @BeforeTest: The annotated method will be run before any test method belonging to the classes inside the <test> tag is run.
- @BeforeGroups: The list of groups that this configuration method will run before. This method is guaranteed to run shortly before the first test method that belongs to any of these groups is invoked.
- @BeforeClass: The annotated method will be run before the first test method in the current class is invoked.
- @BeforeMethod: The annotated method will be run before each test method.
When I am in production and have issue that has big influence to the others, I always make a branch from trunk in order to not bother development other developer, if my issue has finished, I just have to merge my branch to trunk. then how? there are several way to through it, some of which are :
- Using visual diff/merge tool like meld
- Using reintegrate svn command.
For easily way, especially if your changes is not too much. You can using merge tool application that you can find in internet (remember if it’s paid application, the property is belong to respective owners). I am usually using meld, very easy to use. You can check the diff in file, folder and svn! 😀
Beberapa waktu yang lalu saya ingin mengkonversi beberapa file video saya ke format mp3, dulu ketika di Windows itu bisa dilakukan dengan mudah, cukup googling sebentar dan cari applikasi yang cocok dan kompatibel, beres. Tapi berhubung saya terhitung baru di linux, saya agak kebingungan bagaimana mengkonversinya, ternyata mengkonversi file video di Linux tidak sesulit yang saya bayangkan :D. Linux sudah mempunyai repository yang berhubungan dengan codec dan audio. kita hanya tinggal menggunakannya saja. Ada 2 cara dalam mengkonversi file ini, yaitu :
Sometimes you need process that running continuously, every day, every hour, every month or whatever. With this article, i’ll show you how to using of crontab, very simple and easy to use. you can using crontab for synchronize file, update your application, send email, etc. Crontab is linux time based scheduler, user can put the scheduler even its shell scripts or command to run periodically in background. If you want to see what kind of scheduler that regulated, open your terminal and run : Continue reading