diff --git a/spec/models/pages_domain_spec.rb b/spec/models/pages_domain_spec.rb
index 0b95bf594c52b0aca11192d6ced85dc02d95ac2b..0cbea5be10623ba712ad07cd1906955bd7a87311 100644
--- a/spec/models/pages_domain_spec.rb
+++ b/spec/models/pages_domain_spec.rb
@@ -23,13 +23,13 @@ describe PagesDomain, models: true do
     context 'no domain' do
       let(:domain) { nil }
 
-      it { is_expected.to_not be_valid }
+      it { is_expected.not_to be_valid }
     end
 
     context 'invalid domain' do
       let(:domain) { '0123123' }
 
-      it { is_expected.to_not be_valid }
+      it { is_expected.not_to be_valid }
     end
 
     context 'domain from .example.com' do
@@ -37,7 +37,7 @@ describe PagesDomain, models: true do
 
       before { allow(Settings.pages).to receive(:host).and_return('domain.com') }
 
-      it { is_expected.to_not be_valid }
+      it { is_expected.not_to be_valid }
     end
   end
 
@@ -47,13 +47,13 @@ describe PagesDomain, models: true do
     context 'when only certificate is specified' do
       let(:domain) { build(:pages_domain, :with_certificate) }
 
-      it { is_expected.to_not be_valid }
+      it { is_expected.not_to be_valid }
     end
 
     context 'when only key is specified' do
       let(:domain) { build(:pages_domain, :with_key) }
 
-      it { is_expected.to_not be_valid }
+      it { is_expected.not_to be_valid }
     end
 
     context 'with matching key' do
@@ -65,7 +65,7 @@ describe PagesDomain, models: true do
     context 'for not matching key' do
       let(:domain) { build(:pages_domain, :with_missing_chain, :with_key) }
 
-      it { is_expected.to_not be_valid }
+      it { is_expected.not_to be_valid }
     end
   end
 
@@ -157,6 +157,6 @@ describe PagesDomain, models: true do
     subject { domain.certificate_text }
 
     # We test only existence of output, since the output is long
-    it { is_expected.to_not be_empty }
+    it { is_expected.not_to be_empty }
   end
 end
diff --git a/spec/services/pages_service_spec.rb b/spec/services/pages_service_spec.rb
index 254b4f688cf7a46a8e33c699f62aa4cc8f1e1970..b4215b2cd02fa7a560c63a7fb6b0248762f1a903 100644
--- a/spec/services/pages_service_spec.rb
+++ b/spec/services/pages_service_spec.rb
@@ -26,7 +26,7 @@ describe PagesService, services: true do
         before { build.status = status }
 
         it 'should not execute worker' do
-          expect(PagesWorker).to_not receive(:perform_async)
+          expect(PagesWorker).not_to receive(:perform_async)
           service.execute
         end
       end
@@ -40,7 +40,7 @@ describe PagesService, services: true do
     end
 
     it 'should not execute worker' do
-      expect(PagesWorker).to_not receive(:perform_async)
+      expect(PagesWorker).not_to receive(:perform_async)
       service.execute
     end
   end
diff --git a/spec/services/projects/update_pages_service_spec.rb b/spec/services/projects/update_pages_service_spec.rb
index 4eac787586400ff683018f1777a8f3f5c8aa0da4..af1c6a5e7b5af5c428505b6d22eade2a78bf32a9 100644
--- a/spec/services/projects/update_pages_service_spec.rb
+++ b/spec/services/projects/update_pages_service_spec.rb
@@ -34,7 +34,7 @@ describe Projects::UpdatePagesService do
 
       it 'limits pages size' do
         stub_application_setting(max_pages_size: 1)
-        expect(execute).to_not eq(:success)
+        expect(execute).not_to eq(:success)
       end
 
       it 'removes pages after destroy' do
@@ -49,29 +49,29 @@ describe Projects::UpdatePagesService do
       it 'fails if sha on branch is not latest' do
         pipeline.update_attributes(sha: 'old_sha')
         build.update_attributes(artifacts_file: file)
-        expect(execute).to_not eq(:success)
+        expect(execute).not_to eq(:success)
       end
 
       it 'fails for empty file fails' do
         build.update_attributes(artifacts_file: empty_file)
-        expect(execute).to_not eq(:success)
+        expect(execute).not_to eq(:success)
       end
     end
   end
 
   it 'fails to remove project pages when no pages is deployed' do
-    expect(PagesWorker).to_not receive(:perform_in)
+    expect(PagesWorker).not_to receive(:perform_in)
     expect(project.pages_deployed?).to be_falsey
     project.destroy
   end
 
   it 'fails if no artifacts' do
-    expect(execute).to_not eq(:success)
+    expect(execute).not_to eq(:success)
   end
 
   it 'fails for invalid archive' do
     build.update_attributes(artifacts_file: invalid_file)
-    expect(execute).to_not eq(:success)
+    expect(execute).not_to eq(:success)
   end
   
   def execute