Commit Graph

51 Commits

Author SHA1 Message Date
Sam
435d4d51a4 add support for controller tests 2017-05-30 17:33:01 -04:00
Sam
3aa3c915e7 detect dead qunit 2017-05-24 12:24:34 -04:00
Sam
f5f4c36795 Increase autospec qunit timeout to 600 seconds
Correct it so it refocuses on correct runner after running a test
JS tests can not focus on line so skip in vim mode
2017-05-02 16:02:14 -04:00
Sam
556ef4cfbd FIX: case sensitive unconditional add of exact match in user search 2017-05-01 14:37:16 -04:00
Sam
a5fc51a967 improve QUNIT support for autospec 2017-05-01 13:50:28 -04:00
Sam Saffron
dafc4ec906 qunit runner in autospec has been a mess, opening moves to get it working 2017-04-30 19:45:29 -04:00
Sam Saffron
f04fbf911a FEATURE: in vim dev you can focus on spec line in autospec
instructions in bin/notify_file_change
2017-04-25 09:13:29 -07:00
Sam
2bc3aa7ed4 remove no digest refs
the digestless special dev behavior is no longer needed
2017-04-18 17:05:33 -04:00
Sam
2d636406dc FIX: in some case bundle exec fails from spawn
there is some bundler magic in here, prefer bin stubs anyway
cause they are a bit faster
2017-04-13 17:24:58 -04:00
Sam
22214f5e5c Upgrade the Listen gem 2017-04-13 10:39:36 -04:00
Sam
a3e8c3cd7b FEATURE: Native theme support
This feature introduces the concept of themes. Themes are an evolution
of site customizations.

Themes introduce two very big conceptual changes:

- A theme may include other "child themes", children can include grand
children and so on.

- A theme may specify a color scheme

The change does away with the idea of "enabled" color schemes.

It also adds a bunch of big niceties like

- You can source a theme from a git repo

- History for themes is much improved

- You can only have a single enabled theme. Themes can be selected by
    users, if you opt for it.

On a technical level this change comes with a whole bunch of goodies

- All CSS is now compiled using a custom pipeline that uses libsass
    see /lib/stylesheet

- There is a single pipeline for css compilation (in the past we used
    one for customizations and another one for the rest of the app

- The stylesheet pipeline is now divorced of sprockets, there is no
   reliance on sprockets for CSS bundling

- CSS is generated with source maps everywhere (including themes) this
    makes debugging much easier

- Our "live reloader" is smarter and avoid a flash of unstyled content
   we run a file watcher in "puma" in dev so you no longer need to run
   rake autospec to watch for CSS changes
2017-04-12 10:53:49 -04:00
Sam
58c2389a7b FEATURE: in dev use #focus to focus on failing test
(comment should be just above the def line)
2016-07-08 12:58:30 +10:00
Sam
29f6d960c6 FIX: autospec not monitoring correctly 2015-12-17 13:17:57 +11:00
Andy Waite
3e50313fdc Prepare for separation of RSpec helper files
Since rspec-rails 3, the default installation creates two helper files:
* `spec_helper.rb`
* `rails_helper.rb`

`spec_helper.rb` is intended as a way of running specs that do not
require Rails, whereas `rails_helper.rb` loads Rails (as Discourse's
current `spec_helper.rb` does).

For more information:

https://www.relishapp.com/rspec/rspec-rails/docs/upgrade#default-helper-files

In this commit, I've simply replaced all instances of `spec_helper` with
`rails_helper`, and renamed the original `spec_helper.rb`.

This brings the Discourse project closer to the standard usage of RSpec
in a Rails app.

At present, every spec relies on loading Rails, but there are likely
many that don't need to. In a future pull request, I hope to introduce a
separate, minimal `spec_helper.rb` which can be used in tests which
don't rely on Rails.
2015-12-01 20:39:42 +00:00
Sam
ad3dd161e7 FEATURE: first class group mentions built in
If you allow a group to be mentioned it can be mentioned with the @ symbol.

Keep in mind as a safety mechanism max_users_notified_per_group_mention is set to 100
2015-11-30 17:08:43 +11:00
Sam
eaae72c3e4 improve watching logic 2015-11-02 13:24:24 +11:00
Régis Hanol
e7e96eb8af fix the run-qunit scripts with backward compatible syntax 2015-08-25 17:37:36 +02:00
Régis Hanol
294669c856 FIX qunit test runner for phantomjs 2.0 2015-08-25 10:42:19 +02:00
Sam
374f951c65 fix live css changes on mobile 2015-06-22 14:35:11 +10:00
Sam
0681d8f150 qunit is opt in now 2015-05-22 11:22:12 +10:00
Sam
b0306fd613 DEV: make autospec compatible with rspec 3 2015-05-14 11:24:48 +10:00
Sam
bb20f64cb2 use standard error so its easier to catch 2015-03-23 12:20:50 +11:00
Sam
b916108927 be a bit more forgiving with reloader 2015-02-27 17:19:30 +11:00
Robin Ward
d0fb8bbcfc Instead of .js.handlebars use .hbs for handlebars templates 2014-09-26 15:23:15 -04:00
Akshay
6301a43d57 Not initializing variable for looping if unused in loop 2014-08-15 03:24:55 +05:30
Neil Lalonde
a644947119 FIX: live reload of css 2014-06-03 10:16:59 -04:00
Neil Lalonde
c4d3aa3d47 Theming: a UI to choose some base colors that are applied to all the site css. CSS compiled outside of asset pipeline. 2014-05-14 10:18:12 -04:00
Nick Schonning
3782fbed2b JSHint run-qunit.js
- Turn on devel for console and phantom for the phantomjs globals
- Remove unnecessary semicolons
- Use strict comparisons
- Add missing var statements used by for…in
2014-03-11 03:10:55 -04:00
Neil Lalonde
617a605ca2 NO_QUNIT=1 disables qunit in autospec 2013-11-28 11:04:53 -05:00
Régis Hanol
e45ab7d4a8 fix rspec reloaders 2013-11-05 14:53:35 +01:00
Régis Hanol
eb9c1f28ed add debug mode to autospec 2013-11-05 11:01:17 +01:00
Régis Hanol
b56b11d96a add qunit to autospec 2013-11-01 23:57:50 +01:00
Sam
b40d15f81d correct runner so you can run it in non-spork mode 2013-10-24 13:34:38 +11:00
Sam
1357f16563 add a simple runner for autospec 2013-10-24 12:08:03 +11:00
Sam
5bf26ec34e large refactor, ship a few columns from the user table into user_stats 2013-10-07 15:04:59 +11:00
Neil Lalonde
9efa29e688 Detect whether to use mobile view. Session var mobile_view can override automatic detection. 2013-08-27 14:57:42 -04:00
Sam
1eecb0cee5 use sigterm as opposed to hup, cause spork was not handling the hup correctly 2013-08-15 12:55:45 +10:00
Sam
1f0de36e41 extract method 2013-08-15 11:11:14 +10:00
Sam
628ec101c7 minor refactoring 2013-08-06 06:34:42 +10:00
Sam
db196ee126 rake autospec should handle css file watching and reloading, guard is a bit pear shape at the moment 2013-07-10 12:16:56 +10:00
Régis Hanol
6d1d887b96 relaunch all the specs when a fabricator is modified 2013-07-06 19:05:23 +02:00
Sam
e9ebadb414 Nuke message_bus_observer move to service class and classes
Secure all messages triggered by post creation and all user actions so they don't leak
(meaning, if you have a browser open and secure topics are created you will only get them if you are allowed to see them)
2013-05-16 15:03:16 +10:00
Sam
b0945599b7 enter will either run all specs or tell you which failed 2013-05-06 15:16:53 +10:00
Sam
8b419794f9 added option to force polling instead of messing with the detection 2013-05-01 10:29:39 +10:00
Sam
2c4bd484af vagrant detection attempt 2013-05-01 10:04:47 +10:00
Sam
acc4f73ba0 very subtle, autospec was not using inotify if guard was already running 2013-04-30 22:54:52 +10:00
Sam
b25a5a20bb option to strip links from excerpts 2013-04-30 13:25:55 +10:00
Sam Saffron
94a578e4b2 ignore assets
fix runner so it works on mac
get rid of some test warnings
2013-04-30 12:43:59 +10:00
Sam
5ccc3edcbe bug fixes with test runner 2013-04-26 16:18:54 +10:00
Sam
9cf03b352c fix rspec runner for neil 2013-04-26 16:18:54 +10:00