asker-tool 2.3.0 → 2.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 426d13cb48d1dc13c0363945a5e22a4e3228983e616f3f4e2f56a3e2bab9dd53
4
- data.tar.gz: b39f0e3e55643503d40de9f965e09f32a7ee612f6adc6a306b02d25779c5d904
3
+ metadata.gz: 19f1b59f4c03c3860a9fee649625822e17d4a72e36a0e97e23094669a0a27f89
4
+ data.tar.gz: 5f039c02f0af9573a780591ad3672dc0a88dd569f8321773b19606e5f7677100
5
5
  SHA512:
6
- metadata.gz: 224bdd9d8ee79ce875375165d55a761b27d532be298bf593c71f43957caf26fb25d8a8f89fb5aea164538017c4f071c36d0d763784f706dc577de73b1cd3938e
7
- data.tar.gz: 8328b35acbd8962726a8f5ff5104f22e08b884b5de002aeba01654609bbeaa9901d6fc10aff5bca1bc49970ea43b65b8df1e9b4e7d7c6e3d6a8f65fce935fc41
6
+ metadata.gz: 10a4be2178720682d5d9dddcce6d94ee0fa28deaed7f637bd4ed662d302ac8a5c3174ec6f16ac5cf5cc69c5e8eace73e7ae5ce7408d591af7ef4c0dccdf7542c
7
+ data.tar.gz: 99b279f214b6ae3f9d3316e73958c30992727ff73e8f3082f4cb2c7b0ea225c139587dd6345442646e064389f76e29c3e687034aaf52063d2bd42060c095119c
@@ -33,8 +33,9 @@ class Application
33
33
  @config['questions']['stages'] = stages.map(&:to_sym)
34
34
 
35
35
  fractions = @config['questions']['fractions'].split(',')
36
- @config['questions']['fractions'] = fractions
37
-
36
+ @config['questions']['fractions'] = fractions + Array.new(5, '0')
37
+ # require 'debug'; binding.break
38
+
38
39
  Rainbow.enabled = false
39
40
  Rainbow.enabled = true if @config['global']['color'].downcase == 'yes'
40
41
  end
@@ -47,6 +47,7 @@ formula_weights = 1, 1, 1
47
47
 
48
48
  ; Default values
49
49
  ; fractions = 0 to disable
50
+ ; Only used for multichoice questions
50
51
  fractions = 0, -50, -33.33, -25, -20
51
52
 
52
53
  ; List of values d,b,f,i,s,t
@@ -36,7 +36,6 @@
36
36
  </feedback>
37
37
  </answer>
38
38
  <%
39
- question.bads.shuffle! if question.shuffle?
40
39
  question.bads.each do |i|
41
40
  %>
42
41
  <answer fraction="<%= penalty %>" format="html">
@@ -15,6 +15,7 @@ module QuestionMoodleFormatter
15
15
  fractions = Application.instance.config['questions']['fractions']
16
16
  # penalties = ['', '-50', '-33.33333', '-25', '-20']
17
17
  penalties = fractions
18
+
18
19
  penalty = penalties[question.bads.size]
19
20
  template = File.read(File.join(File.dirname(__FILE__), 'moodle', 'multichoice.erb'))
20
21
  when :boolean
data/lib/asker/version.rb CHANGED
@@ -2,7 +2,7 @@
2
2
  # Global parameters
3
3
  module Version
4
4
  MAJOR_NUMBER = '2.3'
5
- VERSION = "#{MAJOR_NUMBER}.0"
5
+ VERSION = "#{MAJOR_NUMBER}.1"
6
6
  NAME = 'asker'
7
7
  GEM = 'asker-tool'
8
8
  CONFIGFILE = 'asker.ini'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: asker-tool
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.3.0
4
+ version: 2.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Vargas Ruiz