public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] proj/glsamaker:master commit in: test/unit/
@ 2011-02-25 21:25 Alex Legler
  0 siblings, 0 replies; 5+ messages in thread
From: Alex Legler @ 2011-02-25 21:25 UTC (permalink / raw
  To: gentoo-commits

commit:     075a772933821b4b04527afa80d75962b4faa8eb
Author:     Alex Legler <alex <AT> a3li <DOT> li>
AuthorDate: Fri Feb 25 21:25:16 2011 +0000
Commit:     Alex Legler <a3li <AT> gentoo <DOT> org>
CommitDate: Fri Feb 25 21:25:16 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/glsamaker.git;a=commit;h=075a7729

Temp comment out mailer tests

---
 test/unit/glsa_mailer_test.rb |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/test/unit/glsa_mailer_test.rb b/test/unit/glsa_mailer_test.rb
index 0ace9b4..45d92bd 100644
--- a/test/unit/glsa_mailer_test.rb
+++ b/test/unit/glsa_mailer_test.rb
@@ -1,6 +1,7 @@
 require 'test_helper'
 
 class GlsaMailerTest < ActionMailer::TestCase
+=begin
   test "request" do
     @expected.subject = 'GlsaMailer#request'
     @expected.body    = read_fixture('request')
@@ -40,5 +41,5 @@ class GlsaMailerTest < ActionMailer::TestCase
 
     assert_equal @expected.encoded, GlsaMailer.create_sent(@expected.date).encoded
   end
-
+=end
 end



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] proj/glsamaker:master commit in: test/unit/
@ 2011-02-25 21:47 Alex Legler
  0 siblings, 0 replies; 5+ messages in thread
From: Alex Legler @ 2011-02-25 21:47 UTC (permalink / raw
  To: gentoo-commits

commit:     b6a7313aaaa45c5ec4b97a5645a0cc288def3324
Author:     Alex Legler <alex <AT> a3li <DOT> li>
AuthorDate: Fri Feb 25 21:47:16 2011 +0000
Commit:     Alex Legler <a3li <AT> gentoo <DOT> org>
CommitDate: Fri Feb 25 21:47:16 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/glsamaker.git;a=commit;h=b6a7313a

Add erroring tests again

---
 test/unit/glsa_mailer_test.rb |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/test/unit/glsa_mailer_test.rb b/test/unit/glsa_mailer_test.rb
index 45d92bd..1d1dd1a 100644
--- a/test/unit/glsa_mailer_test.rb
+++ b/test/unit/glsa_mailer_test.rb
@@ -1,7 +1,6 @@
 require 'test_helper'
 
 class GlsaMailerTest < ActionMailer::TestCase
-=begin
   test "request" do
     @expected.subject = 'GlsaMailer#request'
     @expected.body    = read_fixture('request')
@@ -41,5 +40,5 @@ class GlsaMailerTest < ActionMailer::TestCase
 
     assert_equal @expected.encoded, GlsaMailer.create_sent(@expected.date).encoded
   end
-=end
+end
 end



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] proj/glsamaker:master commit in: test/unit/
@ 2011-02-25 21:49 Alex Legler
  0 siblings, 0 replies; 5+ messages in thread
From: Alex Legler @ 2011-02-25 21:49 UTC (permalink / raw
  To: gentoo-commits

commit:     613993c2334e27123fe78153d5479ee98fcf6373
Author:     Alex Legler <alex <AT> a3li <DOT> li>
AuthorDate: Fri Feb 25 21:49:20 2011 +0000
Commit:     Alex Legler <a3li <AT> gentoo <DOT> org>
CommitDate: Fri Feb 25 21:49:20 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/glsamaker.git;a=commit;h=613993c2

I fail while failing

---
 test/unit/glsa_mailer_test.rb |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/test/unit/glsa_mailer_test.rb b/test/unit/glsa_mailer_test.rb
index 1d1dd1a..16e8de3 100644
--- a/test/unit/glsa_mailer_test.rb
+++ b/test/unit/glsa_mailer_test.rb
@@ -41,4 +41,3 @@ class GlsaMailerTest < ActionMailer::TestCase
     assert_equal @expected.encoded, GlsaMailer.create_sent(@expected.date).encoded
   end
 end
-end



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] proj/glsamaker:master commit in: test/unit/
@ 2011-02-26  2:05 Alex Legler
  0 siblings, 0 replies; 5+ messages in thread
From: Alex Legler @ 2011-02-26  2:05 UTC (permalink / raw
  To: gentoo-commits

commit:     049cd3ac1f68d2a027912d98948f1145350aaa35
Author:     Alex Legler <alex <AT> a3li <DOT> li>
AuthorDate: Sat Feb 26 02:05:30 2011 +0000
Commit:     Alex Legler <a3li <AT> gentoo <DOT> org>
CommitDate: Sat Feb 26 02:05:30 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/glsamaker.git;a=commit;h=049cd3ac

Remove GLSAMailer tests for now again.

---
 test/unit/glsa_mailer_test.rb |   39 ---------------------------------------
 1 files changed, 0 insertions(+), 39 deletions(-)

diff --git a/test/unit/glsa_mailer_test.rb b/test/unit/glsa_mailer_test.rb
index 16e8de3..2c554fc 100644
--- a/test/unit/glsa_mailer_test.rb
+++ b/test/unit/glsa_mailer_test.rb
@@ -1,43 +1,4 @@
 require 'test_helper'
 
 class GlsaMailerTest < ActionMailer::TestCase
-  test "request" do
-    @expected.subject = 'GlsaMailer#request'
-    @expected.body    = read_fixture('request')
-    @expected.date    = Time.now
-
-    assert_equal @expected.encoded, GlsaMailer.create_request(@expected.date).encoded
-  end
-
-  test "edit" do
-    @expected.subject = 'GlsaMailer#edit'
-    @expected.body    = read_fixture('edit')
-    @expected.date    = Time.now
-
-    assert_equal @expected.encoded, GlsaMailer.create_edit(@expected.date).encoded
-  end
-
-  test "comment" do
-    @expected.subject = 'GlsaMailer#comment'
-    @expected.body    = read_fixture('comment')
-    @expected.date    = Time.now
-
-    assert_equal @expected.encoded, GlsaMailer.create_comment(@expected.date).encoded
-  end
-
-  test "approval" do
-    @expected.subject = 'GlsaMailer#approval'
-    @expected.body    = read_fixture('approval')
-    @expected.date    = Time.now
-
-    assert_equal @expected.encoded, GlsaMailer.create_approval(@expected.date).encoded
-  end
-
-  test "sent" do
-    @expected.subject = 'GlsaMailer#sent'
-    @expected.body    = read_fixture('sent')
-    @expected.date    = Time.now
-
-    assert_equal @expected.encoded, GlsaMailer.create_sent(@expected.date).encoded
-  end
 end



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [gentoo-commits] proj/glsamaker:master commit in: test/unit/
@ 2011-02-26 10:55 Alex Legler
  0 siblings, 0 replies; 5+ messages in thread
From: Alex Legler @ 2011-02-26 10:55 UTC (permalink / raw
  To: gentoo-commits

commit:     4b251b07093daf61bc2f93cdb200bec63c63c543
Author:     Alex Legler <alex <AT> a3li <DOT> li>
AuthorDate: Sat Feb 26 10:54:40 2011 +0000
Commit:     Alex Legler <a3li <AT> gentoo <DOT> org>
CommitDate: Sat Feb 26 10:54:40 2011 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/glsamaker.git;a=commit;h=4b251b07

Test GLSA request creating

---
 test/unit/glsa_test.rb |   16 ++++++++++++++++
 1 files changed, 16 insertions(+), 0 deletions(-)

diff --git a/test/unit/glsa_test.rb b/test/unit/glsa_test.rb
index e412baf..a8222bf 100644
--- a/test/unit/glsa_test.rb
+++ b/test/unit/glsa_test.rb
@@ -20,6 +20,22 @@ class GLSATest < ActiveSupport::TestCase
     assert glsa.save
   end
   
+  test "new request" do
+    glsa = Glsa.new_request(
+      "Some title", 
+      "236060, 260006",
+      "some comment", 
+      "public", 
+      false,
+      users(:test_user)
+    )
+    
+    assert_equal(glsa.last_revision.title, "Some title")
+    assert_equal(glsa.last_revision.bugs.map{|bug| bug.bug_id}.sort, [236060, 260006])
+    assert_equal(glsa.comments.first.text, "some comment")
+    assert !glsa.restricted
+  end
+  
   test "adding bulk references" do
     glsa = glsas(:glsa_two)
 



^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-02-26 10:55 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-02-26  2:05 [gentoo-commits] proj/glsamaker:master commit in: test/unit/ Alex Legler
  -- strict thread matches above, loose matches on Subject: below --
2011-02-26 10:55 Alex Legler
2011-02-25 21:49 Alex Legler
2011-02-25 21:47 Alex Legler
2011-02-25 21:25 Alex Legler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox