test: fix default value for additional param
authorSakthipriyan Vairamani <thechargingvolcano@gmail.com>
Wed, 26 Aug 2015 09:52:43 +0000 (15:22 +0530)
committerJeremiah Senkpiel <fishrock123@rocketmail.com>
Tue, 15 Sep 2015 17:53:37 +0000 (13:53 -0400)
commit52019a1b21ced489cfc9077795f6170a1fa19dc1
treecfbe6d66cf14a838cc47e51142a67d64cb9c3fa3
parent59d03738cc63e265544430045b8461ca8b777157
test: fix default value for additional param

In Python, the default values of parameters are evaluated only once
during their declaration. So, whenever the default parameter is used
the same object will be used. Since we use a list, which is a mutable
object, this could lead to unexpected results.

PR-URL: https://github.com/nodejs/node/pull/2553
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
test/testpy/__init__.py