Skip to content
Snippets Groups Projects
  1. Sep 10, 2019
  2. Aug 28, 2019
  3. Aug 26, 2019
  4. Aug 23, 2019
  5. Aug 01, 2019
    • Sean McGivern's avatar
      Add RSpec/TopLevelDescribePath cop · ab0a6455
      Sean McGivern authored
      The RSpec/FilePath cop checks that a spec file's path is correct, but
      only if the file describes a constant. We want to check, for any file
      with a top-level `describe`, whether the file path ends in
      `_spec.rb`. We don't care what comes before that; just that it will be
      executed by RSpec at all.
      ab0a6455
  6. Jul 30, 2019
    • Yorick Peterse's avatar
      Extend cop for verifying injecting of EE modules · cc6619a8
      Yorick Peterse authored
      This extends the InjectEnterpriseEditionModule RuboCop cop so that it
      verifies the following:
      
      1. The line number the injection occurs on (as before).
      2. The method used (e.g. prepend instead of prepend_if_ee).
      3. The argument type passed when using the new module injection methods.
      Unverified
      cc6619a8
  7. Jul 10, 2019
  8. Jun 21, 2019
  9. May 21, 2019
  10. May 20, 2019
  11. May 05, 2019
  12. May 03, 2019
  13. Apr 29, 2019
  14. Apr 15, 2019
  15. Mar 27, 2019
  16. Jan 16, 2019
  17. Dec 13, 2018
    • Yorick Peterse's avatar
      Added Cop for injecting EE modules · 7c580556
      Yorick Peterse authored
      This Cop enforces the rule that injecting EE modules (using prepend,
      include, or extend) is done by placing the injection on the last line of
      a file, instead of somewhere in the middle. By placing these lines at
      the very end, merge conflicts will not happen.
      Verified
      7c580556
  18. Nov 27, 2018
    • Toon Claes's avatar
      Make add_reference cop accept a hash for :index · 54b63919
      Toon Claes authored
      It might happen you want to make the reference column have a unique
      value, or you want to create partial indexes. So instead of only
      accepting a `true` value, also accept a hash of options.
      54b63919
  19. Nov 22, 2018
  20. Oct 31, 2018
  21. Oct 15, 2018
  22. Sep 24, 2018
  23. Sep 21, 2018
  24. Sep 19, 2018
    • Bob Van Landuyt's avatar
      Remove unused constant · 23d55015
      Bob Van Landuyt authored
      This removes an unused constant from the
      `RubyInterpolationInTranslation`. The constant was used in a first
      implementation of this class.
      23d55015
  25. Sep 17, 2018
    • Yorick Peterse's avatar
      Added FromUnion to easily select from a UNION · 8a72f5c4
      Yorick Peterse authored
      This commit adds the module `FromUnion`, which provides the class method
      `from_union`. This simplifies the process of selecting data from the
      result of a UNION, and reduces the likelihood of making mistakes. As a
      result, instead of this:
      
          union = Gitlab::SQL::Union.new([foo, bar])
      
          Foo.from("(#{union.to_sql}) #{Foo.table_name}")
      
      We can now write this instead:
      
          Foo.from_union([foo, bar])
      
      This commit also includes some changes to make this new setup work
      properly. For example, a bug in Rails 4
      (https://github.com/rails/rails/issues/24193) would break the use of
      `from("sub-query-here").includes(:relation)` in certain cases. There was
      also a CI query which appeared to repeat a lot of conditions from an
      outer query on an inner query, which isn't necessary.
      
      Finally, we include a RuboCop cop to ensure developers use this new
      module, instead of using Gitlab::SQL::Union directly.
      
      Fixes https://gitlab.com/gitlab-org/gitlab-ce/issues/51307
      Verified
      8a72f5c4
  26. Sep 11, 2018
  27. Sep 05, 2018
  28. Aug 29, 2018
Loading