Skip to content

Configuring exercise settings

Individual settings of an exercise are configured in the exercise-config.json file of this exercise.

InformationIMPORTANT: If you change the file names specified in exercise-config.json, be sure to update them in the exercise-config.json file as well.

To configure settings for an exercise, complete these steps:

  1. In the LMS authoring interface, go to Authoring > Labs.
  2. Switch to the Coding labs tab.
  3. In the filter, select Drafts.
  4. Click the lab and wait till the lab opens.
  5. Open CODE > exercises > {the exercise you need}.
  6. Click exercise-config.json and in the editor pane specify the following parameters:
ParameterDescriptionValue typeDefault value
testsList of test files that need to be run to check the learner's solution to the exercise. If there are multiple files, separate them with commas."tests": [ "leap_tests1.py", "leap_tests2.py" ]
tests_typeSet the type of auto-tests to use for learners' answers assessment in this exercise. The available types are: * unit — learners' results are compared with the expected result. * input — learners' results are compared with test-cases in the form of stdin input that you will need to write. See Creating input tests.unit
masked-testList of test files for which the correct answers should be hidden from learners. Only whether the learner has passed or failed the exercise will be displayed."masked-test": [ "leap_masked_tests.py" ]
max_pointsIf the exercise needs to be graded, the maximum score for the successful implementation.Decimal
display_execution_timeParameter that defines whether to show the program execution time to learners. This parameter is useful when there is a time restriction for the learner.
pinnedParameter that pins important files to the editor working area in a particular order so that a learner has them in front of their eyes."pinned": [ "file1.py", "file2.py" ]
  1. Click Save in the upper-right corner of the lab window.