Mercurial > hg
view .jshintrc @ 44987:a28d1eca6507
tests: use proctutil.stdout.write() instead of print() in test-extension.t
I was debugging this test failure on python3 + chg. I get the following hunk as
test failure:
```
@@ -206,6 +206,18 @@ Check normal command's load order of ext
4) bar uipopulate
5) foo reposetup
5) bar reposetup
+ 4) foo uipopulate (chg !)
+ 4) bar uipopulate (chg !)
+ 4) foo uipopulate (chg !)
+ 4) bar uipopulate (chg !)
+ 4) foo uipopulate (chg !)
+ 4) bar uipopulate (chg !)
+ 4) foo uipopulate (chg !)
+ 4) bar uipopulate (chg !)
+ 4) foo uipopulate (chg !)
+ 4) bar uipopulate (chg !)
+ 5) foo reposetup (chg !)
+ 5) bar reposetup (chg !)
0:c24b9ac61126
```
After hours of debugging and head scracthing, I figured out that something is
wrong with output flushing. I initially switched the print() statements to
ui.warn() but thanks to Yuya who suggested using procutil.stdout.write()
instead.
author | Pulkit Goyal <7895pulkit@gmail.com> |
---|---|
date | Thu, 18 Jun 2020 17:54:39 +0530 |
parents | bdd2e18b54c5 |
children |
line wrap: on
line source
{ // Enforcing "eqeqeq" : true, // true: Require triple equals (===) for comparison "forin" : true, // true: Require filtering for..in loops with obj.hasOwnProperty() "freeze" : true, // true: prohibits overwriting prototypes of native objects such as Array, Date etc. "nonbsp" : true, // true: Prohibit "non-breaking whitespace" characters. "undef" : true, // true: Require all non-global variables to be declared (prevents global leaks) // Environments "browser" : true // Web Browser (window, document, etc) }