[Piglit] [PATCH 05/10] profile.py: load_test_profile: return errorcode 2

Dylan Baker baker.dylan.c at gmail.com
Thu Jan 29 15:31:20 PST 2015


This allows us to distinguish between a failure in load_test_profile
and a failure in an integrated tests suite.

Signed-off-by: Dylan Baker <dylanx.c.baker at intel.com>
---
 framework/profile.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/framework/profile.py b/framework/profile.py
index fb1007a..a291fdc 100644
--- a/framework/profile.py
+++ b/framework/profile.py
@@ -288,8 +288,9 @@ def load_test_profile(filename):
         return mod.profile
     except AttributeError:
         print("Error: There is not profile attribute in module {0}."
-              "Did you specify the right file?".format(filename))
-        sys.exit(1)
+              "Did you specify the right file?".format(filename),
+              file=sys.stderr)
+        sys.exit(2)
 
 
 def merge_test_profiles(profiles):
-- 
2.2.2



More information about the Piglit mailing list