myexperiment-hackers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[myexperiment-hackers] [2291] trunk/lib/sanity_test.rb: added a basic ve


From: noreply
Subject: [myexperiment-hackers] [2291] trunk/lib/sanity_test.rb: added a basic version integrity check
Date: Fri, 30 Oct 2009 08:26:43 -0400 (EDT)

Revision
2291
Author
dgc
Date
2009-10-30 08:26:42 -0400 (Fri, 30 Oct 2009)

Log Message

added a basic version integrity check

Modified Paths

Diff

Modified: trunk/lib/sanity_test.rb (2290 => 2291)


--- trunk/lib/sanity_test.rb	2009-10-27 15:54:27 UTC (rev 2290)
+++ trunk/lib/sanity_test.rb	2009-10-30 12:26:42 UTC (rev 2291)
@@ -90,8 +90,18 @@
   # workflows
 
   should_be_empty("All workflows must have a content type",
-      workflows.select do |w| !w.content_type.nil? end)
+      workflows.select do |w| w.content_type.nil? end)
 
+  should_be_empty("All workflows must have a license",
+      workflows.select do |w| w.license.nil? end)
+
+  # versioning
+
+  should_be_empty("All workflows versions should be contiguous",
+      workflows.select do |w|
+      w.versions.map do |v| v.version end != (1..w.versions.length).to_a
+      end)
+      
   @results_string += "\nTotal tests:      address@hidden"
   @results_string += "Successful tests: address@hidden do |r| r == true end.length}\n"
   @results_string += "Failed tests:     address@hidden do |r| r == false end.length}\n\n"

reply via email to

[Prev in Thread] Current Thread [Next in Thread]