flok 0.0.28 → 0.0.29

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f82df8fe777e321fa0e840d65ebbe9785687e8a7
4
- data.tar.gz: b1849ab7091668351c73ecbf956dcb0eee4f232b
3
+ metadata.gz: 814b9ab5667695a4b37509a02cb109d34b492017
4
+ data.tar.gz: 8e1abadd518096d523acd3ed37adc0b22e1b87e2
5
5
  SHA512:
6
- metadata.gz: 0c730ef6c242593b47e52304ab893b80c1cdaab4ef5b2a4ef45be09914a2c1abcd22e2cb9b0becd9013b9865c43150ba8e510248f9d1230a071f894ab8230f7f
7
- data.tar.gz: 108f3682c8bb045c887918563fdf175d2ec682c119e6cfd2e749a10dcaafbae3e588711ecc9f2352b5d988090fb56349746a2f5d40230705528202a7426581b6
6
+ metadata.gz: 50d39d48772d80a9fa82df7d687eeaa2a17270be8398777345ae9e1a2d1c9afc3f594044c9ab6de9c43db3de7c73b5481ab5f73df7fbdcb5e3fca9856d493962
7
+ data.tar.gz: 959c40b892fddfc36f7b0633b8498eb04a1427493bd6da5fa8a1db937a2258f6d1f262a95428746a318d208dd0d400c2a2f8aa9f053a86be408f6fa1d7d5b3e5
data/lib/flok/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Flok
2
- VERSION = "0.0.28"
2
+ VERSION = "0.0.29"
3
3
  end
data/spec/etc/cli_spec.rb CHANGED
@@ -35,12 +35,12 @@ def flok_new
35
35
  end
36
36
 
37
37
  RSpec.describe "CLI" do
38
- before(:all) do
38
+ before(:all) do
39
39
  #Uninstall old gems and install the current development gem
40
40
  system("rake gem:install")
41
41
  end
42
42
 
43
- it "Can be executed via bundle exec" do
43
+ it "Can be executed via bundle exec" do
44
44
  Flok.platforms.each do |platform|
45
45
  ENV['PLATFORM'] = platform
46
46
  flok_new do
@@ -71,7 +71,7 @@ it "Can create a new project with correct directories" do
71
71
  ENV['PLATFORM'] = platform
72
72
  flok_new do
73
73
  #Build a new project
74
- flok "build #{platform}"
74
+ flok "build"
75
75
 
76
76
  #Check it's products directory
77
77
  expect(dirs).to include "products"
@@ -106,7 +106,7 @@ it "Can create a new project with correct directories" do
106
106
  File.write "./app/controllers/controller0.rb", controller_src if path
107
107
 
108
108
  #Build a new project
109
- flok "build #{@platform}"
109
+ flok "build"
110
110
 
111
111
  #Check it's products directory
112
112
  Dir.chdir "products" do
@@ -135,16 +135,11 @@ it "Can create a new project with correct directories" do
135
135
  end
136
136
  end
137
137
 
138
- include SpecHelpers
138
+ include SpecHelpers
139
139
  it "server does build project when first run" do
140
140
  Flok.platforms.each do |platform|
141
141
  ENV['PLATFORM'] = platform
142
142
  flok_new do
143
- #Start the server
144
- #Get path to the flok binary relative to this file
145
- bin_path = File.join(File.dirname(__FILE__), "../../bin/flok")
146
- lib_path = File.join(File.dirname(__FILE__), "../../lib")
147
-
148
143
  #Now execute the command with a set of arguments
149
144
  sh2("bundle exec flok server", /BUILD RAN/) do |inp, out|
150
145
  #The server should always trigger a build on it's first run
@@ -176,11 +171,6 @@ it "Can create a new project with correct directories" do
176
171
  Flok.platforms.each do |platform|
177
172
  ENV['PLATFORM'] = platform
178
173
  flok_new do
179
- #Start the server
180
- #Get path to the flok binary relative to this file
181
- bin_path = File.join(File.dirname(__FILE__), "../../bin/flok")
182
- lib_path = File.join(File.dirname(__FILE__), "../../lib")
183
-
184
174
  #Now execute the command with a set of arguments
185
175
  sh2("bundle exec flok server", /BUILD RAN/) do |inp, out|
186
176
  #Get the original build
@@ -215,17 +205,14 @@ it "Can create a new project with correct directories" do
215
205
  Flok.platforms.each do |platform|
216
206
  ENV['PLATFORM'] = platform
217
207
  flok_new do
218
- #Start the server
219
- #Get path to the flok binary relative to this file
220
- bin_path = File.join(File.dirname(__FILE__), "../../bin/flok")
221
- lib_path = File.join(File.dirname(__FILE__), "../../lib")
222
-
223
208
  #Now execute the command with a set of arguments
224
209
  sh2("bundle exec flok server", /BUILD RAN/) do |inp, out|
225
210
  real_application_user_js = File.read("products/#{platform}/application_user.js")
226
211
 
227
212
  #Grab the application_user.js file
228
213
  res = wget "http://localhost:9992/application_user.js"
214
+ expect(res).not_to eq(nil)
215
+ expect(res.length).not_to eq(0)
229
216
  expect(res).to eq(real_application_user_js)
230
217
  end
231
218
  end
@@ -236,11 +223,6 @@ it "Can create a new project with correct directories" do
236
223
  Flok.platforms.each do |platform|
237
224
  ENV['PLATFORM'] = platform
238
225
  flok_new do
239
- #Start the server
240
- #Get path to the flok binary relative to this file
241
- bin_path = File.join(File.dirname(__FILE__), "../../bin/flok")
242
- lib_path = File.join(File.dirname(__FILE__), "../../lib")
243
-
244
226
  #Now execute the command with a set of arguments
245
227
  sh2("bundle exec flok server", /BUILD RAN/) do |inp, out|
246
228
  #Get the original
@@ -262,9 +244,9 @@ it "Can create a new project with correct directories" do
262
244
  #Grab new version
263
245
  application_user_js2 = wget "http://localhost:9992/application_user.js"
264
246
 
265
- #Make sure the compiled file is different and it's somewhat valid (length > 30)
266
- expect(application_user_js2).not_to eq(application_user_js)
267
- expect(application_user_js2.length).to be > 30 #Magic 30 to avoid any problems
247
+ #Make sure the compiled file is different and it's longer
248
+ expect(application_user_js2.length).to be > application_user_js.length
249
+ expect(application_user_js2.length).to be > 30 #Make sure it's at least something
268
250
  end
269
251
  end
270
252
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: flok
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.28
4
+ version: 0.0.29
5
5
  platform: ruby
6
6
  authors:
7
7
  - seo