[Swift-commit] r3303 - SwiftApps/adem-osg

noreply at svn.ci.uchicago.edu noreply at svn.ci.uchicago.edu
Mon May 3 14:56:12 CDT 2010


Author: aespinosa
Date: 2010-05-03 14:56:12 -0500 (Mon, 03 May 2010)
New Revision: 3303

Modified:
   SwiftApps/adem-osg/adem-test.rb
   SwiftApps/adem-osg/adem.rb
Log:
List available pacman packages

Modified: SwiftApps/adem-osg/adem-test.rb
===================================================================
--- SwiftApps/adem-osg/adem-test.rb	2010-05-03 19:56:10 UTC (rev 3302)
+++ SwiftApps/adem-osg/adem-test.rb	2010-05-03 19:56:12 UTC (rev 3303)
@@ -8,7 +8,7 @@
   module TestSetup
     def setup
       @conf = {
-        :pacman_cache         => "http://www.ci.uchicago.edu/~aespinosa/pacman",
+        :pacman_cache         => "http://www.ci.uchicago.edu/~aespinosa/Cybershake",
         :ress_server          => "osg-ress-1.fnal.gov",
         :virtual_organization => "engage"
       }
@@ -50,6 +50,15 @@
     # Must report to osg support then
     assert assumption, "Missing attributes: \n\t#{missing.uniq.join(", ")}"
   end
+
+  def test_app_avail
+    pacman_cache = @conf[:pacman_cache]
+    response = <<-eos
+http://www.ci.uchicago.edu/~aespinosa/Cybershake
+    [ ] jbsim3d
+    eos
+    assert_equal(response, app_avail(pacman_cache))
+  end
 end
 
 class OfflineTest < Test::Unit::TestCase

Modified: SwiftApps/adem-osg/adem.rb
===================================================================
--- SwiftApps/adem-osg/adem.rb	2010-05-03 19:56:10 UTC (rev 3302)
+++ SwiftApps/adem-osg/adem.rb	2010-05-03 19:56:12 UTC (rev 3303)
@@ -107,6 +107,9 @@
   "app"
 end
 
+def app_avail(pacman_cache)
+  `pacman -trust-all-caches -lc #{pacman_cache}`
+end
 def config(args, config_file)
   load_config File.open(config_file)
 end




More information about the Swift-commit mailing list