runeblog 0.0.76 → 0.0.77

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ea20b5ece2e1160b2d6a908b9cdf4dfb84669c39
4
- data.tar.gz: d4624f623f98991472ed1d477266c93e193ecd50
3
+ metadata.gz: b1569e4f78adc608707f4eb19abcb8fb93a02fbc
4
+ data.tar.gz: ea6dddca0418de9a86335ed056187e28951ae952
5
5
  SHA512:
6
- metadata.gz: 2854f7c068e1a26b5106beed39390fa9ecf4e01183cf836f932ad205df6065a07280b98482c13cace608a0ff7687ba585bd819f812ab4f33b978711efd5dfcd3
7
- data.tar.gz: 30682686fa0ea29edb6fb0db128b28cc5bcfddc2b746f90299743564bde6390b7ebbfb0e3d85f1b61d96402b649ce843990ddf6f092e13ea2b8b5dbb821e3e5d
6
+ metadata.gz: 8d97b86002bb3573ca90d4dad60606d0b274d27496e875e4fbefa9046a0265114c0d2434402467c7c3816dbda72955603b16d255acacdbc77a89b05f37d229c1
7
+ data.tar.gz: 1459f0d97b66954d116307bd7b9695f81107a8ecf378e593f18aae3edf9ca67145e83101495dac973a77f1df7afd220541b738df822ea74a0e7e328708bf91ff
data/data/VERSION CHANGED
@@ -1 +1 @@
1
- RuneBlog v 0.0.76 2018-10-04
1
+ RuneBlog v 0.0.77 2018-10-04
data/lib/runeblog.rb CHANGED
@@ -277,6 +277,11 @@ class RuneBlog
277
277
  true
278
278
  end
279
279
 
280
+ def delete_draft(num)
281
+ tag = "#{'%04d' % num.to_i}"
282
+ system("rm -rf #@root/src/#{tag}-*")
283
+ end
284
+
280
285
  def post_exists?(num)
281
286
  list = files_by_id(num)
282
287
  list.empty? ? nil : list
data/lib/version.rb CHANGED
@@ -1,6 +1,6 @@
1
1
 
2
2
  class RuneBlog
3
- VERSION = "0.0.76"
3
+ VERSION = "0.0.77"
4
4
 
5
5
  Path = File.expand_path(File.join(File.dirname(__FILE__)))
6
6
  end
data/test/general.rb CHANGED
@@ -111,12 +111,14 @@ class TestREPL < Minitest::Test
111
111
  end
112
112
 
113
113
  def test_008_current_view!
114
- assert @blog.view.to_s == "alpha_view", "Current view seems wrong (#{@blog.view}, not alpha_view)"
114
+ assert @blog.view.to_s == "alpha_view", "Current view wrong (#{@blog.view}, not alpha_view)"
115
115
  end
116
116
 
117
117
  def test_009_change_view!
118
118
  assert @blog.change_view("beta_view")
119
- assert @blog.view.to_s == "beta_view", "Current view seems wrong (#{@blog.view}, not beta_view)"
119
+ assert @blog.view.to_s == "beta_view", "Current view wrong (#{@blog.view}, not beta_view)"
120
+ assert @blog.change_view("alpha_view")
121
+ assert @blog.view.to_s == "alpha_view", "Current view wrong (#{@blog.view}, not alpha_view)"
120
122
  end
121
123
 
122
124
  def test_010_accessors!
@@ -145,7 +147,9 @@ class TestREPL < Minitest::Test
145
147
  num = @blog.create_new_post(meta, true)
146
148
  assert @blog.posts.size == before + 1, "Don't see new post"
147
149
  @blog.remove_post(num)
150
+ @blog.delete_draft(num) # Hmm
148
151
  assert @blog.posts.size == before, "Failed to delete post"
152
+ @blog.change_view("alpha_view")
149
153
  end
150
154
 
151
155
  def test_013_kill_posts!
data/test/test CHANGED
@@ -1,2 +1,3 @@
1
+ rm -rf data_test
1
2
  ruby test/make_blog.rb
2
3
  ruby test/general.rb
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: runeblog
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.76
4
+ version: 0.0.77
5
5
  platform: ruby
6
6
  authors:
7
7
  - Hal Fulton