whimsical-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From s...@apache.org
Subject [whimsy] branch master updated: Test the Committee API
Date Thu, 24 Oct 2019 18:08:36 GMT
This is an automated email from the ASF dual-hosted git repository.

sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git


The following commit(s) were added to refs/heads/master by this push:
     new 889ee26  Test the Committee API
889ee26 is described below

commit 889ee260b882b515d840496a3f32c99019f6314b
Author: Sebb <sebb@apache.org>
AuthorDate: Thu Oct 24 19:08:33 2019 +0100

    Test the Committee API
---
 lib/spec/lib/site_spec.rb | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/lib/spec/lib/site_spec.rb b/lib/spec/lib/site_spec.rb
index f587519..f5f8a8b 100644
--- a/lib/spec/lib/site_spec.rb
+++ b/lib/spec/lib/site_spec.rb
@@ -6,6 +6,31 @@ require 'spec_helper'
 require 'whimsy/asf'
 
 describe ASF::Site do
+  describe "ASF::Committee::site" do
+    it "should return string for 'httpd'" do
+      res = ASF::Committee.find('HTTP Server').site
+      expect(res).to match(%r{https?://httpd\.apache\.org/?}) 
+    end
+
+    it "should return nil for 'z-z-z'" do
+      res = ASF::Committee.find('z-z-z').site
+      expect(res.class).to eq(NilClass) 
+    end
+  end
+
+  describe "ASF::Committee::description" do
+    it "should return string for 'httpd'" do
+      res = ASF::Committee.find('HTTP Server').description
+      expect(res).to match(%r{Apache Web Server}) 
+    end
+    it "should return nil for 'z-z-z'" do
+      res = ASF::Committee.find('z-z-z').description
+      expect(res.class).to eq(NilClass) 
+    end
+  end
+end
+
+describe ASF::Site do
 
   describe "ASF::Site.find" do
     it "should return hash for 'httpd'" do


Mime
View raw message