mirror of https://github.com/dirtbags/moth.git
Quit dropping KSAs
This commit is contained in:
parent
cf83ea0d7d
commit
85b654e808
|
@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
|
||||||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||||
|
|
||||||
|
## [v4.2.1] - unreleased
|
||||||
|
### Fixed
|
||||||
|
- Transpiled KSAs no longer dropped
|
||||||
|
|
||||||
## [v4.2.0] - 2020-03-26
|
## [v4.2.0] - 2020-03-26
|
||||||
### Changed
|
### Changed
|
||||||
- example/5/draggable.js fix for FireFox to prevent dropping a draggable trying to load a URL
|
- example/5/draggable.js fix for FireFox to prevent dropping a draggable trying to load a URL
|
||||||
|
|
|
@ -17,6 +17,9 @@ success:
|
||||||
mastery: say mrr
|
mastery: say mrr
|
||||||
attachments:
|
attachments:
|
||||||
- moo.txt
|
- moo.txt
|
||||||
|
ksas:
|
||||||
|
- a1
|
||||||
|
- b2
|
||||||
---
|
---
|
||||||
YAML body
|
YAML body
|
||||||
`)
|
`)
|
||||||
|
|
|
@ -184,6 +184,7 @@ func (fp FsPuzzle) Puzzle() (Puzzle, error) {
|
||||||
puzzle.Answers = static.Answers
|
puzzle.Answers = static.Answers
|
||||||
puzzle.Authors = static.Authors
|
puzzle.Authors = static.Authors
|
||||||
puzzle.Objective = static.Objective
|
puzzle.Objective = static.Objective
|
||||||
|
puzzle.KSAs = static.KSAs
|
||||||
puzzle.Success = static.Success
|
puzzle.Success = static.Success
|
||||||
puzzle.Body = string(body)
|
puzzle.Body = string(body)
|
||||||
puzzle.AnswerPattern = static.AnswerPattern
|
puzzle.AnswerPattern = static.AnswerPattern
|
||||||
|
|
|
@ -35,6 +35,12 @@ func TestPuzzle(t *testing.T) {
|
||||||
if p.Success.Mastery != "say mrr" {
|
if p.Success.Mastery != "say mrr" {
|
||||||
t.Error("Wrong Success.Mastery")
|
t.Error("Wrong Success.Mastery")
|
||||||
}
|
}
|
||||||
|
if len(p.KSAs) != 2 {
|
||||||
|
t.Error("KSAs are wrong")
|
||||||
|
}
|
||||||
|
if p.KSAs[0] != "a1" {
|
||||||
|
t.Error("KSAs[0] wrong")
|
||||||
|
}
|
||||||
if p.Body != "<p>YAML body</p>\n" {
|
if p.Body != "<p>YAML body</p>\n" {
|
||||||
t.Errorf("Body parsed wrong: %#v", p.Body)
|
t.Errorf("Body parsed wrong: %#v", p.Body)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue