Skip to content

Commit c650dd4

Browse files
authored
Merge pull request #179 from datacamp/doc-update-squash
docs - theme fixes, move rest of wiki, flesh out
2 parents 295db1d + acc1f20 commit c650dd4

20 files changed

Lines changed: 349 additions & 138 deletions

docs/source/Home.md

Lines changed: 5 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
Home
22
====
33

4+
At DataCamp we build tools to [learn data science](https://www.datacamp.com) interactively. See e.g. our online [R tutorial](https://www.datacamp.com/courses/free-introduction-to-r) to learn R Programming and our Python For Data Science tutorial to [learn Python](https://www.datacamp.com/courses/intro-to-python-for-data-science).
5+
46
pythonwhat?
57
-----------
68

@@ -25,52 +27,17 @@ When a student submits an answer, his or her submission is executed and the outp
2527

2628
If, during execution of the SCT, a test function notices a mistake, an appropriate feedback will be generated and presented to the student. It is always possible to override these feedback messages with your own messages. Defining custom feedback will make your SCTs longer and they may be error prone (typos, etc.), but they typically give the exercise a more natural and personalized feel.
2729

28-
If all test functions pass, a success message is presented to the student. `pytonwhat` has some messages in store from which it can choose randomly, but you can override this with the `success_msg()` function.
30+
If all test functions pass, a success message is presented to the student. `pythonwhat` has some messages in store from which it can choose randomly, but you can override this with the `success_msg()` function.
2931

3032
Overview
3133
--------
3234

33-
To get started, make sure to check out the [Quickstart Guide](https://www.github.com/datacamp/pythonwhat/wiki/Quickstart_Guide).
35+
To get started, make sure to check out the [Quickstart Guide](quickstart_guide.md).
3436

35-
To robustly test the equality of objects, and results of evaluations, it has to fetch the information from the respective processes, i.e. the student and solution processes. By default, this is done through a process of 'dilling' and 'undilling', but it's also possible to define your own converters to customize the way objects and results are compared. For more background on this, check out the [Processes article](https://github.com/datacamp/pythonwhat/wiki/Processes). For some more background on the principle of 'sub-SCTs', i.e. sets of tests to be called on a particular part or a particular state of a student's submission, have a look at the [Sub-SCTs article](https://github.com/datacamp/pythonwhat/wiki/Sub-SCTs).
37+
To robustly test the equality of objects, and results of evaluations, it has to fetch the information from the respective processes, i.e. the student and solution processes. By default, this is done through a process of 'dilling' and 'undilling', but it's also possible to define your own converters to customize the way objects and results are compared. For more background on this, check out the [Processes article](expression_tests.md). For some more background on the principle of 'sub-SCTs', i.e. sets of tests to be called on a particular part or a particular state of a student's submission, have a look at the [Part Checks article](part_checks.rst).
3638

3739
The remainder of the wiki goes over every test function that `pythonwhat` features, explaining all arguments and covering different use cases. They will give you an idea of how, why and when to use them.
3840

39-
**Basic functions**
40-
41-
- Multiple choice exercises: [test_mc()](https://github.com/datacamp/pythonwhat/wiki/test_mc)
42-
- What student typed: [test_student_typed()](https://github.com/datacamp/pythonwhat/wiki/test_student_typed)
43-
- Which output is generated: [test_output_contains()](https://github.com/datacamp/pythonwhat/wiki/test_output_contains)
44-
- Value of object: [test_object()](https://github.com/datacamp/pythonwhat/wiki/test_object)
45-
- Usage of objects: [test_object_accessed()](https://github.com/datacamp/pythonwhat/wiki/tets_object_accessed)
46-
- Usage of function: [test_function()](https://github.com/datacamp/pythonwhat/wiki/test_function)
47-
- Usage of function, v2 (improved): [test_function_v2()](https://github.com/datacamp/pythonwhat/wiki/test_function_v2)
48-
- Usage of operators: [test_operator()](https://github.com/datacamp/pythonwhat/wiki/test_operator)
49-
- Package imports: [test_import()](https://github.com/datacamp/pythonwhat/wiki/test_import)
50-
51-
**Logic-inducing functions**
52-
53-
- If some tests fail, do other tests to pinpoint the problem: [test_correct()](https://www.github.com/datacamp/pythonwhat/wiki/test_correct)
54-
- Specify several tests, only one of which should pass: [test_or()](https://www.github.com/datacamp/pythonwhat/wiki/test_or)
55-
56-
**Advanced functions**
57-
58-
- Value of data frame: [test_data_frame()](https://github.com/datacamp/pythonwhat/wiki/test_data_frame)
59-
- Value of dictionary: [test_dictionary()](https://github.com/datacamp/pythonwhat/wiki/test_dictionary)
60-
- If ... else ... constructs: [test_if_else()](https://github.com/datacamp/pythonwhat/wiki/test_if_else)
61-
- For loops: [test_for_loop()](https://github.com/datacamp/pythonwhat/wiki/test_for_loop)
62-
- While loops: [test_while_loop()](https://github.com/datacamp/pythonwhat/wiki/test_while_loop)
63-
- Test value of object after expression: [test_object_after_expression()](https://github.com/datacamp/pythonwhat/wiki/test_object_after_expression)
64-
- Test output of an expression: [test_expression_output()](https://github.com/datacamp/pythonwhat/wiki/test_expression_output)
65-
- Test result of an expression: [test_expression_result()](https://github.com/datacamp/pythonwhat/wiki/test_expression_result)
66-
- Context managers, the with statement: [test_with()](https://github.com/datacamp/pythonwhat/wiki/test_with)
67-
- Test user-defined functions: [test_function_definition()](https://github.com/datacamp/pythonwhat/wiki/test_function_definition)
68-
- Test lambda function definitions: [test_lambda_function()](https://github.com/datacamp/pythonwhat/wiki/test_lambda_function)
69-
- Test comprehensions: [test_list_comp(), test_dict_comp() and test_generator_exp()](https://github.com/datacamp/pythonwhat/wiki/test_comprehension)
70-
- Test try except blcoks: [test_try_except()](https://github.com/datacamp/pythonwhat/test_try_except)
71-
72-
All these functions are also documented inside the `pythonwhat` source code itself. The documentation there goes into the tiny details of all functions' implementations. Follow the steps in the README of this repository to generate a PDF version of the documentation.
73-
7441
For more full examples of SCTs for Python exercises on DataCamp, check out the [source files of the introduction to Python course](http://www.github.com/datacamp/courses-intro-to-python). In the chapter files there, you can can see the SCTs that have been written for several exercises.
7542

7643
To test your understanding of writing SCTs for Python exercises on the DataCamp platform, you can take the course [Writing SCTs with pythonwhat](https://www.datacamp.com/courses/writing-scts-with-pythonwhat) course.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
code.docutils.literal {
2+
color: black;
3+
}

docs/source/conf.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -307,9 +307,12 @@ def setup(app):
307307
'auto_toc_tree_section': 'Contents',
308308
}, True)
309309
app.add_transform(AutoStructify)
310+
app.add_stylesheet('theme_overrides.css')
310311

311312
on_rtd = os.environ.get('READTHEDOCS', None) == 'True'
312313
if not on_rtd: # only import and set the theme if we're building docs locally
313314
import sphinx_rtd_theme
314315
html_theme = 'sphinx_rtd_theme'
315316
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
317+
def setup(app):
318+
app.add_stylesheet('theme_overrides.css')

0 commit comments

Comments
 (0)