Skip to content

Commit e88df52

Browse files
committed
Merge branch 'add-controller-tests'
2 parents 65d7b45 + 03acb02 commit e88df52

12 files changed

Lines changed: 93 additions & 14 deletions

File tree

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# Changelog
22

3-
## Unreleased
3+
## 1.0.0 (December 29, 2022)
44
* Add Docker to allow consistent development environment
55
* Remove unneeded files which were added during scaffolding
66
* Declare importmap-rails as required
7-
* Add tests for IngressController
7+
* Add tests for IngressController, system tests and fixes discovered through those tests
88

99
## 0.1.0 (December 25, 2022)
1010
* Initial release

Gemfile.lock

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,11 +76,21 @@ GEM
7676
public_suffix (>= 2.0.2, < 6.0)
7777
ast (2.4.2)
7878
builder (3.2.4)
79+
capybara (3.38.0)
80+
addressable
81+
matrix
82+
mini_mime (>= 0.1.3)
83+
nokogiri (~> 1.8)
84+
rack (>= 1.6.0)
85+
rack-test (>= 0.6.3)
86+
regexp_parser (>= 1.5, < 3.0)
87+
xpath (~> 3.2)
7988
concurrent-ruby (1.1.10)
8089
crack (0.4.5)
8190
rexml
8291
crass (1.0.6)
8392
date (3.3.3)
93+
dropybara (1.0.0)
8494
erubi (1.12.0)
8595
ffi (1.15.5)
8696
globalid (1.0.0)
@@ -104,6 +114,7 @@ GEM
104114
net-pop
105115
net-smtp
106116
marcel (1.0.2)
117+
matrix (0.4.2)
107118
method_source (1.0.0)
108119
mini_magick (4.12.0)
109120
mini_mime (1.1.2)
@@ -177,6 +188,11 @@ GEM
177188
ruby-progressbar (1.11.0)
178189
ruby-vips (2.1.4)
179190
ffi (~> 1.12)
191+
rubyzip (2.3.2)
192+
selenium-webdriver (4.7.1)
193+
rexml (~> 3.2, >= 3.2.5)
194+
rubyzip (>= 1.2.2, < 3.0)
195+
websocket (~> 1.0)
180196
sprockets (4.2.0)
181197
concurrent-ruby (~> 1.0)
182198
rack (>= 2.2.4, < 4)
@@ -195,20 +211,26 @@ GEM
195211
addressable (>= 2.8.0)
196212
crack (>= 0.3.2)
197213
hashdiff (>= 0.4.0, < 2.0.0)
214+
websocket (1.2.9)
198215
websocket-driver (0.7.5)
199216
websocket-extensions (>= 0.1.0)
200217
websocket-extensions (0.1.5)
218+
xpath (3.2.0)
219+
nokogiri (~> 1.8)
201220
zeitwerk (2.6.6)
202221

203222
PLATFORMS
204223
aarch64-linux
205224

206225
DEPENDENCIES
226+
capybara
227+
dropybara
207228
filepond-rails!
208229
image_processing
209230
importmap-rails
210231
puma (~> 6.0)
211232
rubocop (~> 1.1)
233+
selenium-webdriver
212234
sprockets-rails
213235
sqlite3
214236
webmock (~> 3.18)

app/assets/javascripts/filepond-rails.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ let FilePondRails = {
5959
FilePondRails.input = input
6060

6161
// Initialize FilePond on our element
62-
FilePond.create(input, FilePondRails.default_options)
62+
return FilePond.create(input, FilePondRails.default_options)
6363
}
6464
}
6565

filepond-rails.gemspec

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,7 @@ Gem::Specification.new do |spec|
2828
spec.add_development_dependency 'puma', '~> 6.0'
2929
spec.add_development_dependency 'rubocop', '~> 1.1'
3030
spec.add_development_dependency 'webmock', '~> 3.18'
31+
spec.add_development_dependency 'capybara'
32+
spec.add_development_dependency 'dropybara'
33+
spec.add_development_dependency 'selenium-webdriver'
3134
end
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# frozen_string_literal: true
2+
3+
require 'test_helper'
4+
5+
class ApplicationSystemTestCase < ActionDispatch::SystemTestCase
6+
driven_by :selenium, using: :chrome, screen_size: [1400, 1400], options: {
7+
browser: :remote,
8+
url: ENV['SELENIUM_REMOTE_URL']
9+
}
10+
end

test/dummy/app/javascript/application.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ window.FilePond = FilePond
44
window.FilePondRails = FilePondRails
55

66
const input = document.querySelector('.filepond')
7-
FilePondRails.create(input)
7+
window.filePondInstance = FilePondRails.create(input)

test/dummy/app/views/layouts/application.html.erb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<!DOCTYPE html>
22
<html>
33
<head>
4-
<title>Dummy</title>
4+
<title>filepond-rails Dummy App</title>
55
<meta name="viewport" content="width=device-width,initial-scale=1">
66
<%= csrf_meta_tags %>
77
<%= csp_meta_tag %>

test/fixtures/files/toronto.png

-1.66 MB
Loading

test/integration/.keep

Whitespace-only changes.

test/integration/navigation_test.rb

Lines changed: 0 additions & 9 deletions
This file was deleted.

0 commit comments

Comments
 (0)