marcingrzejszczak / gradle-test-profiler

created with @AChudzik. The idea of this plugin is to perform profiling of your tests. You will be able to see your test execution times sorted in the descending manner together with an information about a module and the class name from which the test was executed.
Apache License 2.0
25 stars 11 forks source link

Excel 2010 doesn't handle field separator in reports corretly #19

Closed achudzik closed 8 years ago

achudzik commented 9 years ago

Excel 2010 ignores the following field separators:

and use locale (and Windows) specific "list separator" property (e.g. semicolon).

See this Stackoverflow question for more details.

mattfirtion commented 8 years ago

I tried modifying the separator String in the testprofiler section, but the report will outputs tabs.

apply plugin: 'java'

buildscript {
    repositories {
        mavenCentral()
        jcenter()
    }
    dependencies {
        classpath 'com.blogspot.toomuchcoding:gradle-test-profiler:0.3.1'
    }
}

apply plugin: 'com.blogspot.toomuchcoding.testprofiler'

repositories {
    mavenCentral()
}

dependencies {
    testCompile 'junit:junit:4.8.2'
}

testprofiler {  
    String separator = "|"
}
marcingrzejszczak commented 8 years ago

@achudzik - can you address this issue?

marcingrzejszczak commented 8 years ago

@mattfirtion - I'll try to take a look at this tomorrow. I'm really sorry for the delay.

marcingrzejszczak commented 8 years ago

@mattfirtion - you have written

testprofiler {  
    String separator = "|"
}

whereas you should

testprofiler {  
    separator = "|"
}

You have initialized a variable separator instead of setting it. Can you try like I just wrote and retry?

mattfirtion commented 8 years ago

@marcingrzejszczak, that worked. I'd suggest changing README.md to match. Any thought on changing the default from tabs to comma separated?

marcingrzejszczak commented 8 years ago

@mattfirtion - that would make perfect sense - I'll try to do that today. Is now readme better ? (https://github.com/marcingrzejszczak/gradle-test-profiler/commit/475307484c8b41fea7a25557671da5722fe4327c)

mattfirtion commented 8 years ago

Definitely! I love the idea behind this plugin.

marcingrzejszczak commented 8 years ago

Enjoy :) https://bintray.com/marcingrzejszczak/com-blogspot-toomuchcoding/gradle-test-profiler/0.3.2/view

Version 0.3.2 released with comma as default separation