Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support output-style property #142

Merged

Conversation

francescocervone
Copy link
Contributor

Closes #140

@runningcode
Copy link
Owner

runningcode commented Jul 8, 2020

Thank you for the contribution! Would you be able to change the string to use Lazy Properties?

Should we be defaulting to using single as the default? I would assume that most flank use cases run more than one shard. Is this broken for all cases using more than one shard?

@francescocervone
Copy link
Contributor Author

francescocervone commented Jul 8, 2020

@runningcode you are welcome!

Would you be able to change the string to use Lazy Properties?

Of course.

Should we be defaulting to using single as the default?

I didn't because it looked weird to me that Fladle overrides some Flank's property's default. As a Fladle user, I'd prefer to default output style to single, though. It's your call.

Is this broken for all cases using more than one shard?

What do you mean when you say "for all cases"? I tried with just 2 shards and with 50 shards. The issue occurs in both cases.

@runningcode
Copy link
Owner

Thanks for using the lazy property!

What do you mean when you say "for all cases"? I tried with just 2 shards and with 50 shards. The issue occurs in both cases.

I mean if it improves the experience for 2 shards and 50 shards, I think we should make it the default? The only case where it degrades the experience is for 1 shard? Is that true?

@francescocervone
Copy link
Contributor Author

Yes, as far as I understand.

Copy link
Owner

@runningcode runningcode left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! I will merge this tomorrow.

@Test
fun writeOutputStyle() {
val properties = emptyExtension {
outputStyle.set("anyString")
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i guess this will fail when the flank command is executed?
i'm fine with that, just wanted to point it out. i don't think validating this option on the fladle side makes sense in case more options are introduced by flank down the line.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I did that on purpose for the same reason you pointed out.

@@ -44,6 +44,7 @@ internal class YamlWriter {
val smartFlankDisableUpload = config.smartFlankDisableUpload
val localResultsDir = config.localResultsDir.orNull
val testTargetsAlwaysRun = config.testTargetsAlwaysRun
val outputStyle = config.outputStyle.orNull
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i think orNull isn't necessary or has no effect here since the convention is set.

@runningcode runningcode merged commit 4cd2fda into runningcode:master Jul 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Duplicate status messages
2 participants