Read about our upcoming Code of Conduct on this issue

Commit 19c7133d authored by George Tsiolis's avatar George Tsiolis
Browse files

Fix typos in comments and specs

parent 0360938132ae
......@@ -7,7 +7,7 @@
expect(convert_html("Hello")).to eq('Hello')
end
it "strips non-color-changing controll sequences" do
it "strips non-color-changing control sequences" do
expect(convert_html("Hello \e[2Kworld")).to eq('Hello world')
end
......
......@@ -24,7 +24,7 @@
expect(policy).to be_satisfied_by(pipeline, seed)
end
it 'is not satisfied by an overriden empty variable' do
it 'is not satisfied by an overridden empty variable' do
policy = described_class.new(['$CI_PROJECT_NAME'])
expect(policy).not_to be_satisfied_by(pipeline, seed)
......
......@@ -219,7 +219,7 @@
##
# When nodes are specified but not defined, we assume that
# configuration is valid, and we asume that entry is simply undefined,
# configuration is valid, and we assume that entry is simply undefined,
# despite the fact, that key is present. See issue #18775 for more
# details.
#
......
......@@ -50,7 +50,7 @@
expect(info.should_run?(dummy_controller)).to be_truthy
end
it 'returns the the oposite of #should_skip? when the check is a skip' do
it 'returns the the opposite of #should_skip? when the check is a skip' do
info = described_class.new({}, nil, nil, true)
expect(info).to receive(:should_skip?).with(dummy_controller).and_return(false)
......@@ -101,7 +101,7 @@
expect(info.should_skip?(dummy_controller)).to be_truthy
end
it 'returns the the oposite of #should_run? when the check is not a skip' do
it 'returns the the opposite of #should_run? when the check is not a skip' do
info = described_class.new({}, nil, nil, false)
expect(info).to receive(:should_run?).with(dummy_controller).and_return(false)
......
......@@ -20,7 +20,7 @@ def migration_project(project)
end
describe "#remove_last_ocurrence" do
it "removes only the last occurance of a string" do
it "removes only the last occurrence of a string" do
input = "this/is/a-word-to-replace/namespace/with/a-word-to-replace"
expect(subject.remove_last_occurrence(input, "a-word-to-replace"))
......
......@@ -566,13 +566,13 @@
end
end
context "for text positon" do
context "for text position" do
let(:args) { args_for_text }
it_behaves_like "diff position json"
end
context "for image positon" do
context "for image position" do
let(:args) { args_for_img }
it_behaves_like "diff position json"
......@@ -592,13 +592,13 @@
end
end
context "for text positon" do
context "for text position" do
let(:args) { args_for_text }
it_behaves_like "diff position json"
end
context "for image positon" do
context "for image position" do
let(:args) { args_for_img }
it_behaves_like "diff position json"
......
......@@ -43,7 +43,7 @@
#
# In any case, all of this means that the tests below will be extremely
# (excessively, unjustifiably) thorough for scenarios where "the file was
# created in the old diff" and then drop off to comparitively lackluster
# created in the old diff" and then drop off to comparatively lackluster
# testing of other scenarios.
#
# I did still try to cover most of the obvious and potentially tricky
......
......@@ -17,7 +17,7 @@
end
it 'handles missing blobs' do
expect { described_class.new(repository, 'non-existant-branch') }.not_to raise_error
expect { described_class.new(repository, 'non-existent-branch') }.not_to raise_error
end
describe '#attributes' do
......
......@@ -96,7 +96,7 @@
expect(described_class.current_home_dir).to eq default_home_dir
end
it 'returns the explicitely set home dir' do
it 'returns the explicitly set home dir' do
GPGME::Engine.home_dir = '/tmp/gpg'
expect(described_class.current_home_dir).to eq '/tmp/gpg'
......@@ -104,7 +104,7 @@
GPGME::Engine.home_dir = GPGME::Engine.dirinfo('homedir')
end
it 'returns the default value when explicitely setting the home dir to nil' do
it 'returns the default value when explicitly setting the home dir to nil' do
GPGME::Engine.home_dir = nil
expect(described_class.current_home_dir).to eq default_home_dir
......
......@@ -321,7 +321,7 @@
end
end
context 'when the project has overriden params in import data' do
context 'when the project has overridden params in import data' do
it 'overwrites the params stored in the JSON' do
project.create_import_data(data: { override_params: { description: "Overridden" } })
......
......@@ -40,7 +40,7 @@
end
end
context 'subject is overriden' do
context 'subject is overridden' do
it 'returns true' do
presenter = presenter_class.new(build_stubbed(:project, :public))
......
......@@ -48,7 +48,7 @@
stub_request(:post, webhook_url).with(body: JSON(body), headers: { 'Content-Type' => 'application/json' }).to_return(status: 200, body: "", headers: {})
end
it 'expects to receive successfull answer' do
it 'expects to receive successful answer' do
expect(subject.ping(options)).to be true
end
end
......
......@@ -76,7 +76,7 @@
end
end
context 'when there are aritfacts in old and new directory' do
context 'when there are artifacts in old and new directory' do
before do
store_artifacts_in_legacy_path(build2)
......
......@@ -41,7 +41,7 @@ def initialize(attrs = {}, *)
expect(minimal_test_class.current_without_cache).to eq(minimal_test_class.last)
end
it 'can be overriden' do
it 'can be overridden' do
minimal_test_class.define_singleton_method(:current_without_cache) do
first
end
......@@ -64,7 +64,7 @@ def initialize(attrs = {}, *)
context 'with defaults defined' do
include_context 'with defaults'
it 'can be overriden' do
it 'can be overridden' do
expect(minimal_test_class.defaults).to eq({ foo: 'a', bar: 'b', baz: 'c' })
end
end
......
......@@ -519,7 +519,7 @@ def spend_time(seconds)
end
end
context 'substracting time' do
context 'subtracting time' do
before do
spend_time(1800)
end
......@@ -530,7 +530,7 @@ def spend_time(seconds)
expect(issue.total_time_spent).to eq(900)
end
context 'when time to substract exceeds the total time spent' do
context 'when time to subtract exceeds the total time spent' do
it 'raise a validation error' do
Timecop.travel(1.minute.from_now) do
expect do
......
......@@ -14,7 +14,7 @@
expect(subject.local_store?).to eq true
end
it 'returns false whe file_store is equal to LfsObjectUploader::Store::REMOTE' do
it 'returns false when file_store is equal to LfsObjectUploader::Store::REMOTE' do
subject.file_store = LfsObjectUploader::Store::REMOTE
expect(subject.local_store?).to eq false
......
......@@ -2746,7 +2746,7 @@ def enable_lfs
.to raise_error(ActiveRecord::RecordNotSaved, error_message)
end
it 'updates the project succesfully' do
it 'updates the project successfully' do
merge_request = create(:merge_request, target_project: project, source_project: project)
expect { project.append_or_update_attribute(:merge_requests, [merge_request]) }
......@@ -3314,7 +3314,7 @@ def enable_lfs
end
end
context 'when explicitely enabled' do
context 'when explicitly enabled' do
context 'when domain is empty' do
before do
create(:project_auto_devops, project: project, domain: nil)
......
......@@ -145,7 +145,7 @@
end
it "returns nil if the page does not exist" do
expect(subject.find_page("non-existant")).to eq(nil)
expect(subject.find_page("non-existent")).to eq(nil)
end
it "can find a page by slug" do
......@@ -226,7 +226,7 @@
end
it 'returns nil if the page does not exist' do
expect(subject.find_file('non-existant')).to eq(nil)
expect(subject.find_file('non-existent')).to eq(nil)
end
it 'returns a Gitlab::Git::WikiFile instance' do
......
......@@ -91,7 +91,7 @@
.to change { upload.checksum }.from(nil).to(expected)
end
it 'sets `checksum` to nil for a non-existant file' do
it 'sets `checksum` to nil for a non-existent file' do
expect(upload).to receive(:exist?).and_return(false)
checksum = Digest::SHA256.file(__FILE__).hexdigest
......
......@@ -565,7 +565,7 @@
}
end
it 'are commited as one in project repo' do
it 'are committed as one in project repo' do
post api(url, user), valid_mo_params
expect(response).to have_gitlab_http_status(201)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment