Commit Graph

24 Commits

Author SHA1 Message Date
jade
ad1d854f43 rework tests to use displayElement, remove DOM clearing per test 2025-01-10 01:02:58 -07:00
vzhang03
bdf4fc3eee Fixed test to use plugin_version 2024-06-25 12:56:27 -04:00
vzhang03
b7bd08aaac Fixed tests by adding version to ignored fields 2024-06-25 10:55:18 -04:00
bjoluc
ab7ad5a435 Handle undefined results 2023-12-06 19:56:24 +01:00
Josh de Leeuw
6f9d01b2ae added record_data parameter 2023-10-30 09:48:07 -04:00
bjoluc
8318d380c1 Merge branch 'main' into core-rewrite 2022-11-09 15:13:58 +01:00
bjoluc
f9f99b5c32 Fix skipped tests 2022-11-09 10:10:27 +01:00
bjoluc
5aa986ef0e Implement save_trial_parameters 2022-10-27 14:25:02 +02:00
bjoluc
89dbfa9875 Adapt implementation to dataparameter.test.ts and fix more data test suites 2022-10-26 20:16:25 +02:00
bjoluc
b9d1eac623 Fix more data test suites 2022-10-26 17:33:12 +02:00
bjoluc
088a974deb Adapt implementation to datamodule.test.ts 2022-10-26 15:43:49 +02:00
Josh de Leeuw
594a7708f9
Update packages/jspsych/tests/data/datacollection.test.ts
Co-authored-by: bjoluc <mail@bjoluc.de>
2022-03-11 12:10:02 -05:00
Josh de Leeuw
4eb61c3e19
Update packages/jspsych/tests/data/datacollection.test.ts
Co-authored-by: bjoluc <mail@bjoluc.de>
2022-03-11 12:09:51 -05:00
Josh de Leeuw
ab1f3214cd add test case for filterColumns 2021-12-17 12:04:04 -05:00
Josh de Leeuw
aa4acc4152 remove #s 2021-12-17 11:59:11 -05:00
bjoluc
ff2827d8c9 Move test utility functions into @jspsych/test-utils 2021-09-28 20:04:19 +02:00
bjoluc
338c1b62b6 Merge branch 'modularization' into modularization-es6-stuff 2021-09-15 11:53:19 +02:00
bjoluc
63acb56dac Re-enable tests that depend on plugins converted in #2078 2021-09-14 18:31:48 +02:00
Josh de Leeuw
a77052deb2 replace var where needed 2021-08-25 11:06:11 -04:00
Josh de Leeuw
266f756155 replace var where needed 2021-08-25 11:05:56 -04:00
bjoluc
c119650471 Move experiment execution into jsPsych.run()
The `run()` method takes a timeline and returns a promise that is
resolved when the experiment finishes.
Hence, jsPsych can now be initialized without starting an experiment.
This re-enables usage of `jsPsych.timelineVariable()` in timeline
definitions and repairs exclusion checks and extension loading.
2021-07-19 17:10:37 +02:00
bjoluc
8cfbba526a Use classes to avoid global state
Instead of a global `jsPsych` object, there is a `JsPsych` class now
which can be instantiated with the parameters that were previously
accepted by `jsPsych.init`. Upon instantiation, the `JsPsych` class also
instantiates classes for stateful modules (`jsPsych.data` and
`jsPsych.pluginAPI`) and passes relevant `JsPsych` instance information
to them. Plugins are expected to be classes now that are instantiated
for each trial and receive the `JsPsych` instance as their only
constructor argument.
2021-07-12 18:15:37 +02:00
bjoluc
91e7b1e3ff Migrate to TypeScript 2021-07-06 17:55:42 +02:00
bjoluc
744e67b0a5 Setup monorepo and switch to ES6 modules
* Convert jsPsych and plugins to ES6 modules
* Create packages for each plugin, the core library, and config files
* Setup rollup, jest, and babel configurations
* Update jsPsych to load plugin objects directly from the `type` field
* Update tests to use the ES6 modules
2021-06-23 22:39:38 +02:00