learningequality / learningequality/studio

Test cleanup for completion/duration tests

Open
#4,183 0 comments 0 reactions 1 assignee View on GitHub

@marcellamaki is already working on this.

Since Jul 4, 2023.

P2 - normal TAG: tech update / debt TAG: unit tests
Dominant language
Python
Stars
191
Forks
307
Avg merge
5d 6h
Merged PRs (30d)
10

Description

It'd be good to place this outside of the describe('getCompletionCriteriaLabels') block, because it doesn't test, neither describe behavior of getCompletionCriteriaLabels function like other tests cases but rather that of getCompletionDataFromNode. This applies to another new test case below as well.

A nice way to try out if tests organizations and descriptions make sense from the documentation point of view is to run the test suite with --verbose flag and read through the output

yarn test-jest channelEdit/__tests__/utils.spec --verbose

Screenshot from 2023-07-04 07-54-35

And this is nitpick (squared), on the screenshot above you can also see that it may be nice to distinguish between audio and video test cases descriptions to be able to say which one corresponds to which as right now, their names are identical. If one of them failed, ideally we'd be able to say immediately if it fails for video or for audio without digging deep into the tests code.

Originally posted by @MisRob in https://github.com/learningequality/studio/pull/4182#discussion_r1251514139

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.