Skip to content
This repository was archived by the owner on Mar 4, 2026. It is now read-only.

Mastery Score should be zero if not defined#7

Open
thomasturrell wants to merge 1 commit into
adlnet:masterfrom
thomasturrell:masteryScore_should_be_zero_if_not_defined
Open

Mastery Score should be zero if not defined#7
thomasturrell wants to merge 1 commit into
adlnet:masterfrom
thomasturrell:masteryScore_should_be_zero_if_not_defined

Conversation

@thomasturrell
Copy link
Copy Markdown

If the LMS does not set a mastery score then the value should be assumed to be 0 because undefined is not a valid value.

@thomasturrell
Copy link
Copy Markdown
Author

thomasturrell commented Jul 8, 2021

@cawerkenthin I would be grateful for your thoughts on this pull request. Should the cmi5Controller use zero for a mastery score if it is undefined or would you say it was up to the cmi5Controller client to check for the possibility of undefined?

As it stands this AU always sends failed statements because the cmi5.xml does not contain a mastery score.

Currently in the following, cmi5Controller.getMasteryScore() is always undefined.

if (score >= cmi5Controller.getMasteryScore()) {
    SendStatement("Passed", score);
} else {
    SendStatement("Failed", score);
}

@cawerkenthin
Copy link
Copy Markdown
Collaborator

I think there are two issues here:

  1. The sample AU includes a test, yet does not provide a mastery score in the cmi5.xml. While that is allowed, it is not a great example.
  2. The controller should check for null. If it is null, it is probably best not to assume an intent of 0 but instead don't send passed or failed statements.

@thomasturrell
Copy link
Copy Markdown
Author

I think that it is ok for a AU not to have a mastery score but still send passed and failed statements, what if the move on criteria was passed?

@thomasturrell
Copy link
Copy Markdown
Author

My question would be is it ok for an AU to have its own build concept of a passing score as long as it was overridden by the mastery score (if one was present)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants