study_engine 0.1.0 → 0.1.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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 16ecce2518dff06ac7838399b400ea2ceee095d8
|
4
|
+
data.tar.gz: 2ff51debe02a84f10a25fd0a6d1763887808c7ab
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c1d287546aef3d1062e2eb437309123222544444fed0bfd2aedd9e32ea311043a14d5fc311f2c7d845a1d8609118c4d9cdd981332b45cda6a20431ef53b51b3c
|
7
|
+
data.tar.gz: ce2c8cdfaa8d053f7a3b9753ddaaa0b0248ae3460273fe765a81f0c0acc08691d305ce8480e206bac4da540fee513228035f8c9276f7781cdcc689ad178e12f0
|
@@ -32,7 +32,7 @@ module StudyEngine
|
|
32
32
|
if assessments.save
|
33
33
|
redirect_to [:admin, :assessments], notice: "Assessment created!"
|
34
34
|
else
|
35
|
-
flash.now
|
35
|
+
flash.now.alert = assessments.errors.full_messages.join(", ")
|
36
36
|
render :new
|
37
37
|
end
|
38
38
|
end
|
@@ -26,10 +26,10 @@ module StudyEngine
|
|
26
26
|
redirect_to assessment
|
27
27
|
end
|
28
28
|
elsif assessment.restartable?
|
29
|
-
flash.now
|
29
|
+
flash.now.alert = "Partial assessment data already exists for this ID number and event. Would you like to resume or restart?"
|
30
30
|
render :restart
|
31
31
|
else
|
32
|
-
flash.now
|
32
|
+
flash.now.alert = assessment.errors.full_messages.join(", ")
|
33
33
|
render :index
|
34
34
|
end
|
35
35
|
end
|
@@ -57,7 +57,7 @@ module StudyEngine
|
|
57
57
|
|
58
58
|
def timeout
|
59
59
|
@assessment = BeginAssessmentForm.new_from_model(assessment)
|
60
|
-
flash.now
|
60
|
+
flash.now.alert = "Assessment timed out due to inactivity. Would you like to resume or restart?"
|
61
61
|
render :restart
|
62
62
|
end
|
63
63
|
|
@@ -60,12 +60,12 @@ When /^I should see the progress bar at (\d+%)$/ do |percent|
|
|
60
60
|
begin
|
61
61
|
find(".percentage", text: percent)
|
62
62
|
rescue Capybara::ElementNotFound
|
63
|
-
find(".percentage").text.
|
63
|
+
expect(find(".percentage").text).to eq(percent)
|
64
64
|
end
|
65
65
|
end
|
66
66
|
|
67
67
|
Then 'I should see the "Start Assessment" form' do
|
68
|
-
page.
|
68
|
+
expect(page).to have_css("form input[value='Start Assessment']")
|
69
69
|
end
|
70
70
|
|
71
71
|
Then "I should see the following assessment results:" do |table|
|
@@ -80,7 +80,7 @@ Then "I should see that notes are present" do
|
|
80
80
|
end
|
81
81
|
|
82
82
|
Then /^I should download a csv named "(.+?)" with the following contents:$/ do |filename, table|
|
83
|
-
page.response_headers['Content-Disposition'].
|
83
|
+
expect(page.response_headers['Content-Disposition']).to include("filename=\"#{filename}\"")
|
84
84
|
page.execute_script """
|
85
85
|
window.xhrDownload = function(url) {
|
86
86
|
var xhr = new XMLHttpRequest();
|
data/lib/study_engine/version.rb
CHANGED