Allow more truthy values for `CUCUMBER_PUBLISH_ENABLED`
See original GitHub issueI tried CUCUMBER_PUBLISH_ENABLED=1
and nothing was published. Any value should be considered truthy except /false|no|0/
. This is how it’s implemented in Cucumber-Ruby.
Issue Analytics
- State:
- Created 3 years ago
- Comments:18 (18 by maintainers)
Top Results From Across the Web
Share reports and living documentation with the whole team
The free Cucumber reports service makes it simple to share living documentation with all team members, instantly. Powered by Cucumber Messages, ...
Read more >Error while running cucumber in junit - java - Stack Overflow
i am trying to run a simple cucumber feature test. below are my feature file, step definition file and junit runner file. but...
Read more >Implementing 'Masterthought' Reports in Cucumber - Dezlearn
Let's learn more about Masterthought reporting plugin in BDD framework. Configuration: 1. First step we need to perform is to add maven ...
Read more >Cucumber reports - Jenkins Plugins
This plugin allows Jenkins to publish the results as pretty html reports hosted by the Jenkins build server. In order for this plugin...
Read more >Data Types - Swagger
string (this includes dates and files); number; integer; boolean; array; object. These types exist in most programming languages, ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I already did. It’s at the first line in this issue. I’ll elaborate for clarity:
Environment variables were introduced in UNIX in the late seventies, and the way C code and shell scripts behave is that any value of an environment variable resolves to a truthy value. This is because the stdlib getenv function either returns a string (truthy) or
NULL
(falsy).This works fine in most cases. If you want falsy, just don’t specify the variable. If you want truthy, specify any value. This means
0
,1
,true
,false
,whatever
are all truthy.This is why I was surprised when
1
was not interpreted as truthy. It deviates from standard UNIX behaviour, and the underlying programming language is irrelevant.The fact that all values are truthy might not be intuitive to some, but it’s the way environment variables are designed to work. Some tools have adopted conventions that deviate from the original behaviour by interpreting a small set of values as falsey. The most common ones seem to be
0
,false
andno
.Git for example, interprets
0
andfalse
as falsey.1
andtrue
as truthy. Any other value is an error. (TryGIT_TRACE=1 git status
).For users who are using the values
true
andfalse
, this change will not alter the behaviour.Users who have specified
1
orbanana
will now get a truthy value instead of a falsey one.Are you suggesting there are users out there who might have been expecting falsey for
1
and other non-true
strings that will now be confused about the new behaviour?(BTW, I agree we should not attempt to internationalise this).
@aslakhellesoy wrong issue?