summaryrefslogtreecommitdiff
path: root/spec/spec_helper.rb
Commit message (Collapse)AuthorAgeFilesLines
* Revert "Merge branch 'revert-04c3c6dd' into 'master'"Rémy Coutable2019-05-221-1/+4
| | | | | This reverts commit 744f1f2e7037f5c70c3168d9e2e89b1c327465d2, reversing changes made to c4d930e5f54e7da07c80cc028dfc0f5c08719146.
* Revert "Merge branch 'reorganize-tests-jobs-by-level' into 'master'"revert-04c3c6ddKamil Trzciński2019-05-221-4/+1
| | | This reverts merge request !27514
* Reorganize test jobs by levelreorganize-tests-jobs-by-levelRémy Coutable2019-05-201-1/+4
| | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Fix unrelated errors when teardowning quanrantined specsavoid-unrelated-errors-in-quarantined-specsRémy Coutable2019-05-101-1/+1
| | | | | | | | | | | | | Since we're skipping the example in a before hook, the @_subscribers instance variable that is normally set in the setup phase of the test by https://github.com/rails/rails-controller-testing/blob/21014e48be124dd8d0af250b79f682519d445015/lib/rails/controller/testing/template_assertions.rb#L21 isn't set but the teardown phase of the example still happens and tries to iterate over the array of subcribers: https://github.com/rails/rails-controller-testing/blob/21014e48be124dd8d0af250b79f682519d445015/lib/rails/controller/testing/template_assertions.rb#L54 Using an around hook allows the @_subscribers instance variable to be set. Signed-off-by: Rémy Coutable <remy@rymai.me>
* Show full Rspec backtrace only in CIHeinrich Lee Yu2019-05-031-1/+1
|
* Add full backtrace for RSpec outputStan Hu2019-04-291-0/+1
| | | | Attempt to debug https://gitlab.com/gitlab-org/gitlab-ce/issues/60953
* Introduce the wait_for helper for system testsce-11224-flaky-test-projects-audit-events-adding-an-ssh-key-appears-in-the-project-s-audit-events-ee-spec-features-projects-audit_events_specRémy Coutable2019-04-181-0/+1
| | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Double retries for rspec-retriesLin Jen-Shin2019-04-101-2/+2
| | | | It was 2*4 => 8 times before, so 4 times is still half retries
* Reduce number of rspec retriesSanad Liaquat2019-04-091-2/+2
| | | | | In both e2e QA tests and unit tests, reduce the number of retires to 2 (i.e., 1 initial and one retry)
* Merge branch '6539-extract-ee-specific-code' into 'master'Rémy Coutable2019-04-011-0/+1
|\ | | | | | | | | Add no-op license helper to CE See merge request gitlab-org/gitlab-ce!26723
| * Add no-op license helper to CE6539-extract-ee-specific-codeAlexandru Croitor2019-03-281-0/+1
| | | | | | | | | | | | | | | | Add no-op license helper to CE to make it compatible with EE codebase. Helper will be overwritten in EE to allow for CE specs to be run under EE codebase. https://gitlab.com/gitlab-org/gitlab-ee/issues/6539
* | Factorize policy helpers into PolicyHelpersRémy Coutable2019-03-271-0/+1
|/ | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Bring back Rugged implementation of find_commitStan Hu2019-03-011-1/+8
| | | | | | | | | | | | | | | | This brings back some of the changes in https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/20339. For users using Gitaly on top of NFS, accessing the Git data directly via Rugged is more performant than Gitaly. This merge request introduces the feature flag `rugged_find_commit` to activate Rugged paths. There are also Rake tasks `gitlab:features:enable_rugged` and `gitlab:features:disable_rugged` to enable/disable these feature flags altogether. Part of four Rugged changes identified in https://gitlab.com/gitlab-org/gitlab-ce/issues/57317.
* Revert the "What's new" featureBrandon Labuschagne2019-01-291-5/+0
|
* Add jobs to run quarantine testsRémy Coutable2019-01-151-1/+1
| | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Allow to quarantine testsRémy Coutable2019-01-151-0/+5
| | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Resolve "Add "What's new" menu item in top navigation"Brandon Labuschagne2019-01-141-0/+5
|
* Merge remote-tracking branch 'upstream/master' into ↵Lin Jen-Shin2018-12-261-1/+1
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 54953-error-500-viewing-merge-request-due-to-nil-commit_email_hostname * upstream/master: (115 commits) [CE] Speed up login page usage Add new line and comments Fix the seeder 24_forks.rb cannot find public project Milestones on community contribution issues Removed Gitlab Upgrader found in /lib/gitlab/upgrader.rb Fix and move specs into admin_disables_git_access_protocol_spec.rb Fix HTTP/SSH clone panel for mobile Add spec for HTTP/SSH clone panel Fix missing Git clone button when protocol restriction setting enabled Fix deprecation: Using positional arguments in integration tests Extend override check to also check arity Update tm cli version Bump Gitaly version to v1.12.0 Add @dbalexandre to CODEOWNERS Update verbiage for clarity Change group-cluster beta to regular note Change alpha states to use note instead of warning Update registry section. Update serverless.yaml formatting Clarify obtaining application URL Add @godfat to CODEOWNERS ...
| * Rename GroupHierarchy into ObjectHierarchyJarka Košanová2018-12-191-1/+1
| | | | | | | | | | | | - we now use the hierarchy class also for epics - also rename supports_nested_groups? into supports_nested_objects? - move it to a concern
* | Make sure we clear the application settings afterLin Jen-Shin2018-12-191-0/+2
| | | | | | | | migration tests.
* | Use fake application settings for migration testsLin Jen-Shin2018-12-191-0/+2
|/
* Merge branch 'fix-rspec-offcense' into 'master'Rémy Coutable2018-12-171-3/+3
|\ | | | | | | | | Fix RSpec/HookArgument rubocop offense See merge request gitlab-org/gitlab-ce!23776
| * Fix RSpec/HookArgument rubocop offenseSemyon Pupkov2018-12-111-3/+3
| |
* | Remove rails 4 support in CI, Gemfiles, bin/ and config/Jasper Maes2018-12-141-4/+0
|/
* Address specs failing in rails 4Jan Provaznik2018-11-141-0/+4
| | | | | | | | | | | We want to run CI with rails 4 for a short-term (until we are sure that we will ship with rails 5). The problem is that rails 4 can not handle rails 5 schema.rb properly - specifically `t.index` directive can not handle multiple indexes on the same column. Because combination of rails 4 + rails 5 schema will be used only in CI for a short-term, we can just ignore these incompatibility failures. This patch adds `rails5` helper for specs.
* Require spec helpers loaded by other spec helpers firstAlejandro Rodríguez2018-10-041-0/+5
|
* Ensure in-memory application settings are cleared before each testRémy Coutable2018-09-101-0/+4
| | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Move fixture_path out of support/rspec file which is used by ↵Thong Kuah2018-08-311-0/+1
| | | | | | | | | fast_spec_helper, so that fast specs can be run on its own again. Move `fixture_path` config together with use_transactional_fixtures and use_instantiated_fixtures. These settings are all added by rspec-rails https://github.com/rspec/rspec-rails/blob/8c6c9590b94916199950dc8a91a9741d3be30c7c/lib/rspec/rails/configuration.rb#L65-L67
* Refactor Rainbow usage in specsGabriel Mazetto2018-08-161-0/+1
| | | | | We don't test any specific string generated by it yet, so there is no point in keeping it enabled when we are disabling it everywhere we test its output.
* Resolve "Enable Auto DevOps instance-wide on GitLab.com"Dylan Griffith2018-08-161-0/+7
|
* Updates from `rubocop -a`Lin Jen-Shin2018-07-091-1/+1
|
* Fix User role displayed on projects dashboardFrancisco Javier López2018-07-061-0/+11
|
* Implement `expect_next_instance_of` and use itLin Jen-Shin2018-06-211-0/+1
| | | | | We need this because `expect_any_instance_of` doesn't work on prepended models. Now we could use the same code between CE/EE
* Port route helper from EE to CELin Jen-Shin2018-06-141-0/+1
|
* Find and mark more Git disk access locations, part 2Jacob Vosmaer2018-06-121-13/+0
|
* Fix Fog mockingKamil Trzciński2018-06-051-0/+4
|
* Support resetting of Prometheus metrics between test runsStan Hu2018-05-091-0/+7
| | | | | | | Adding the :prometheus tag to an rspec test will clear out memory-mapped files and reset the registry. Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/39968
* Introduce Redis helpers. Rename BuildTraceChunkFlushToDbWorker to ↵Shinya Maeda2018-05-041-6/+13
| | | | Ci::BuildTraceChunkFlushWorker.
* Gitlab::Shell works on shard name, not pathZeger-Jan van de Weg2018-04-251-2/+2
| | | | | | | | | | | Direct disk access is done through Gitaly now, so the legacy path was deprecated. This path was used in Gitlab::Shell however. This required the refactoring in this commit. Added is the removal of direct path access on the project model, as that lookup wasn't needed anymore is most cases. Closes https://gitlab.com/gitlab-org/gitaly/issues/1111
* Move spec helpers/matchers/shared examples/contexts to their relevant folderRémy Coutable2018-04-231-28/+31
| | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Introduce a new FactoriesInMigrationSpecs copRémy Coutable2018-04-061-0/+1
| | | | Signed-off-by: Rémy Coutable <remy@rymai.me>
* Use shard name in Git::GitlabProjects instead of shard pathAhmad Sherif2018-04-031-1/+2
| | | | Closes gitaly#1110
* Clean the test path after each spec runStan Hu2018-03-281-0/+4
| | | | | | | | | | FactoryBot's build_stubbed ignores the current database sequence of the projects table and starts at ID 1000. If more than 1000 projects are created during a test run, leftover repositories can cause spec failures. For example, a spec that expects an empty repository may fail since there may be existing content. Closes #5461
* Add HTTPS-only pagesRob Watson2018-03-221-0/+16
| | | | Closes #28857
* Adapt cycle analytics spec helper and cycle analytics usage data spec41777-include-cycle-time-in-usage-pingTiago Botelho2018-03-011-0/+4
|
* Port `read_cross_project` ability from EEBob Van Landuyt2018-02-221-0/+8
|
* Make :migration specs a little more robustMichael Kozono2018-02-161-0/+16
| | | | E.g. https://gitlab.com/gitlab-org/gitlab-ce/-/jobs/52873034
* Ensure hooks are deleted regardless of the project forking methodAlejandro Rodríguez2018-01-191-0/+10
|
* Use an at_exit hook to stop test gitalystop-gitaly-atexitJacob Vosmaer2018-01-151-4/+0
|
* Replace factory_girl_rails with factory_bot_railsrc/use-factory_bot_railsRémy Coutable2017-12-141-1/+1
| | | | | | | | | | | I've followed the [upgrade guide](https://github.com/thoughtbot/factory_bot/blob/4-9-0-stable/UPGRADE_FROM_FACTORY_GIRL.md) and ran these two commands: ``` grep -e FactoryGirl **/*.rake **/*.rb -s -l | xargs sed -i "" "s|FactoryGirl|FactoryBot|" grep -e factory_girl **/*.rake **/*.rb -s -l | xargs sed -i "" "s|factory_girl|factory_bot|" ``` Signed-off-by: Rémy Coutable <remy@rymai.me>