Skip to content

Commit

Permalink
186-add location to fetch_schools
Browse files Browse the repository at this point in the history
  • Loading branch information
Edimo committed Jul 19, 2024
1 parent 45c5b2e commit cbcb9f4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion backend/app/actors/fetch_schools.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def fetch_schools
def params
{
api_key:,
fields: "id,school.name",
fields: "id,school.name,location",
page: 0,
"school.name" => school_name_like
}
Expand Down
6 changes: 4 additions & 2 deletions backend/spec/actors/fetch_schools_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
let(:valid_params) do
{
api_key:,
fields: "id,school.name",
fields: "id,school.name,location",
page: 0,
"school.name" => school_name
}
Expand All @@ -21,7 +21,9 @@
let(:schools) do
[
{ "id" => "1",
"school.name" => school_name }
"school.name" => school_name,
"location.lat" => 42.374471,
"location.lon" => -71.118313 }
]
end

Expand Down

0 comments on commit cbcb9f4

Please sign in to comment.