Skip to content

Why does cucumber run @Before in all glue code files

I have a problem with my cucumber tests. It runs the @Before method in all the glue classes. For example. This feature file have one glue code in the MainStepDef.class. The MainStepDef: I have an additional glue file called: OtherStep.class And finally I have my runner class. When I run this I get the runtime…

toString() representation output

I have a bug in the code and believe me I’ve run debugging many times to find what’s wrong with code but cannot understand what is wrong. I have to output the contents of 2d Arraylist. For example, if I do: it outputs me the following: But when I change the fourth value, 3, to higher number, for e…

I get many select @@session.tx_read_only, would one do the same?

I am using Python to insert value in a database through an API written by someone else in Java. The insertion goes quite slow, and when I look at the mysql log of the transcactions for one insert I see that it often does select @@session.tx_read_only: From http://docs.oracle.com/cd/E17952_01/refman-5.6-en/ser…

Ways to make maven build faster?

I have a multi module java project. Maven takes almost around 40 secs to build it. I have tried maven with multi threaded builds too by specifying -T and -C args for no of threads and cores to be used. But I haven’t seen any significant improvement in wall time of my builds. I am using maven 3.2.3 and s…

How do I convert [[Ljava.lang.String;@7defb4fb] to a String

I am trying to print the String, below is the code: but I get following output in the console: I have tried the following snippets: But all of these are giving similar strange output: How do I get the string value out of it? ** Edit: ** My problem was to print and array of an array in Java. First

How to enable CSS editing in Intellij

I just switched to IntelliJ IDEA because I thought it would be great for developing JavaFX application. I must be doing something wrong because when I am editing a CSS file, there is no code-completion. When I am trying to create a new CSS file there is no option for CSS files. I am using the community versio…