loadNXDTestFile: use `compile` for better tracebacks on errors

When using compile with the actual file path, we can have better tracebacks
in case of errors.

before:

    Traceback (most recent call last):
      File "/srv/slapgrid/slappart3/srv/runner/software/9544feb19475590d240ba2d32743c0a0/bin/nxdtest", line 22, in <module>
        sys.exit(nxdtest.main())
      File "/srv/slapgrid/slappart3/srv/runner/software/9544feb19475590d240ba2d32743c0a0/parts/nxdtest/nxdtest/__init__.py", line 142, in main
        tenv = loadNXDTestFile('.nxdtest')
      File "/srv/slapgrid/slappart3/srv/runner/software/9544feb19475590d240ba2d32743c0a0/parts/nxdtest/nxdtest/__init__.py", line 75, in loadNXDTestFile
        six.exec_(src, g)
      File "<string>", line 77, in <module>
    NameError: name 'Pylint' is not defined

after:

    Traceback (most recent call last):
      File "/srv/slapgrid/slappart3/srv/runner/software/9544feb19475590d240ba2d32743c0a0/bin/nxdtest", line 22, in <module>
        sys.exit(nxdtest.main())
      File "/srv/slapgrid/slappart3/srv/runner/software/9544feb19475590d240ba2d32743c0a0/parts/nxdtest/nxdtest/__init__.py", line 142, in main
        tenv = loadNXDTestFile('.nxdtest')
      File "/srv/slapgrid/slappart3/srv/runner/software/9544feb19475590d240ba2d32743c0a0/parts/nxdtest/nxdtest/__init__.py", line 75, in loadNXDTestFile
        six.exec_(compile(src, os.path.realpath(path), 'exec'), g)
      File "/srv/slapgrid/slappart3/srv/runner/instance/slappart8/var/nxdtest/.nxdtest", line 77, in <module>
        summaryf=Pylint.summary,
    NameError: name 'Pylint' is not defined
2 jobs for feat/compile in 0 seconds

View job dependencies in the pipeline graph!

You can now group jobs in the pipeline graph based on which jobs are configured to run first, if you use the needs: keyword to establish job dependencies in your CI/CD pipelines. Learn how to speed up your pipeline with needs.

Provide feedback
Status Job ID Name Coverage
  External
passed nxdtest.UnitTest-Master.Python2.WIP

00:39:20

passed nxdtest.UnitTest-Master.Python3.WIP

01:02:54

 

Speed up your pipelines with Needs relationships

Using the needs keyword makes jobs run before their stage is reached. Jobs run as soon as their needs relationships are met, which speeds up your pipelines.

If you add needs to jobs in your pipeline you'll be able to view the needs relationships between jobs in this tab as a Directed Acyclic Graph (DAG).