* Add test sampler
* Use let! and let_it_be for article_spec.rb
* Regroup and restructure expectations and tests
* Move private methods in private
* Decrease the needed objects in .seo_boostable test
* Re-use the user
* Newlined
* Refactor raise_error(specific_error) expectation
The full RSpec warining is
```
WARNING: Using `expect { }.not_to raise_error(SpecificErrorClass)` risks false positives,
since literally any other error would cause the expectation to pass,
including those raised by Ruby (e.g. NoMethodError, NameError and ArgumentError),
meaning the code you are intending to test may not even get reached.
Instead consider using `expect { }.not_to raise_error` or `expect { }.to raise_error(DifferentSpecificErrorClass)`.
```
* Refactor jsitor tests to test behaviour
As pointed out by @rhymes, the previous tests were not
testing actual behaviour. This is an attempt at improving the tests.
* Improve format and clarity of the docs [ci skip]
While this change produces a lot of git noise by enacting what seems
like an arbitrary linewrap on most of the files in the documentation it
will result in better version control and tracking of the changes in the
documentation.
For example, as it currently stands, if one was to make a
PR to move a comma in a sentence because each paragraph in most of the
files is on a single line, that small change would look in the git
history like the author had modified the entire paragraph. In reality,
this author just moved a comma.
This change also includes a significant number of modifications to the
more article-esque docs. Many of these docs were written in a sort of
stream-of-conciousness and aren't as easy to read as they could be.
Hopefully this is the first of several readability changes. If we could
get these docs to a more accessible reading level, we would probably see
an increase in contributions. :)
* Delegate markdown wrapping to Prettier
* Add linewrapping explanation in the docs [ci skip]
This test was commented out, but I don't see much information in the
commit message as to why. The Pull Request which this commit was merged
from seems to be lost as well.
This test does seem to pass when it's not commented out, but there must
have been a reason it was commented out.
That being said, the test isn't really *testing* much functionality.
Essentially, it just asserts that a page with the word "settings" on it
renders from several different approaches. This might be problematic
because a false positive would be quite easy.
In light of those things, it makes sense to me that this test should be
removed.
* Replace current_user.id with efficient_current_user_id in high-leverage areas
* Update name of efficient_current_user_id
* Replace user_signed_in? in pageviews
* Remove unneeded ?
* Reduce code duplication in onboarding tests
* Update variable names for consistency
* Improve test descriptions and format
* Refactor a useless test
This test was fairly pointless, but hopefully with this refactor it
could detect a regression? Although, I think it's really just testing
the that the Preact framework's state mechanism is working the way we
expect it to, but it might be worth leaving this test in.
* Add jext-axe package and introduce a11y testing
Automated a11y testing is NOT comprehensive. We cannot expect this to
even scratch the surface of potential a11y issues.
However, we can expect to find a percentage of issues that are currently
flying under the radar. Adopting some automation around a11y testing
also allows us to use CI to find a11y regressions -- which should be
really handy.
I've never really used Jest before, and Preact seems to make it a little
more complicated, but as far as I can tell, this is a decent way to add
at least some minor automated a11y testing.
* Add doc about automated a11y tests
* added tests to specs
* added view logic
* added controller/model functionality
* minor tweak to tagadjustment view
* adjusted mod view to reduce query
* added instance variables to controller
* show already adjusted tags in mod view
* removed unnecessary ifs from mods controller
* catch and display errors to tag adjustment forms
* update specs and refactor
* Add infinite scroll to followers list (#258)
* Refactor fetchNext function for clarity (#258)
* Sepparate following tab into multiple tabs to support infinite scroll (#258)
* Add infinite scroll to following pages (#258)
* Add tests to infinite scroll api
* Refactor dashboard loading text
* Refactor infine scroll function
* Fix duplicated entries problem in infinite scrolling
* Switch randomized attributes to sequential to avoid InvalidRecord error
* Add acceptance tests for infinite scroll
* Remove unused following method
* parameterize limit per page for followers and followings
* Split follows endpoint into followers and followings
* Authenticate user with api key in followers and followings
* Split followers endpoint into users and organizations
* Add redundant html to sublist partial
* Speed up infinite scroll tests
* Refactor api json responses to use partials
* Authenticate api user before follows create
* Resolve conflicts on scrolling js
* Improve partials organization and fix organization username bug
* Improve readability of unauthorized test
* Use let! to create scrolling test data
* Fix not working podcasts link
* Refactor initScrolling to remove linting errors
* Fix codeclimate coding style issue
* Test tags forms and podcasts hyperlinks
* Fix eslint issue with double equals
* Improve before_action usage and readability
* Add - to support dash character in JSitor liquid tag
* Edit spec/liquid_tags/jsitor_tag_spec.rb
* Add support for link with hyphen id in jsitor liquid tag
* Add rate_limit_follow_count_daily to SiteConfig
* Add favicon_url to SiteConfig
* Add logo_svg to SiteConfig
* Add staff_user_id to SiteConfig
* Add default_site_email to SiteConfig
* Add social_networks_handle to SiteConfig
* Add ga_view_id and ga_fetch_rate to SiteConfig
* Add mailchimp newsletters IDs to SiteConfig
* Add periodic_email_digest_max, periodic_email_digest_min to SiteConfig