mirror of
https://github.com/Freika/dawarich.git
synced 2026-01-11 17:51:39 -05:00
Fix failing specs
This commit is contained in:
parent
a56889ef8d
commit
79dab6c491
3 changed files with 20 additions and 18 deletions
File diff suppressed because one or more lines are too long
|
|
@ -341,14 +341,16 @@ RSpec.describe User, type: :model do
|
|||
|
||||
describe '.from_omniauth' do
|
||||
let(:auth_hash) do
|
||||
OmniAuth::AuthHash.new({
|
||||
provider: 'github',
|
||||
uid: '123545',
|
||||
info: {
|
||||
email: email,
|
||||
name: 'Test User'
|
||||
OmniAuth::AuthHash.new(
|
||||
{
|
||||
provider: 'github',
|
||||
uid: '123545',
|
||||
info: {
|
||||
email: email,
|
||||
name: 'Test User'
|
||||
}
|
||||
}
|
||||
})
|
||||
)
|
||||
end
|
||||
|
||||
context 'when user exists with the same email' do
|
||||
|
|
@ -394,14 +396,16 @@ RSpec.describe User, type: :model do
|
|||
context 'when OAuth provider is Google' do
|
||||
let(:email) { 'google@example.com' }
|
||||
let(:auth_hash) do
|
||||
OmniAuth::AuthHash.new({
|
||||
provider: 'google_oauth2',
|
||||
uid: '123545',
|
||||
info: {
|
||||
email: email,
|
||||
name: 'Google User'
|
||||
OmniAuth::AuthHash.new(
|
||||
{
|
||||
provider: 'google_oauth2',
|
||||
uid: '123545',
|
||||
info: {
|
||||
email: email,
|
||||
name: 'Google User'
|
||||
}
|
||||
}
|
||||
})
|
||||
)
|
||||
end
|
||||
|
||||
it 'creates a user from Google OAuth data' do
|
||||
|
|
|
|||
|
|
@ -37,9 +37,7 @@ RSpec.describe PointSerializer do
|
|||
'track_id' => point.track_id,
|
||||
'country_name' => point.read_attribute(:country_name),
|
||||
'raw_data_archived' => point.raw_data_archived,
|
||||
'raw_data_archive_id' => point.raw_data_archive_id,
|
||||
'timestamp_year' => point.timestamp_year,
|
||||
'timestamp_month' => point.timestamp_month
|
||||
'raw_data_archive_id' => point.raw_data_archive_id
|
||||
}
|
||||
end
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue