Skip to content

Commit

Permalink
Fix tests, format code and prepare for release
Browse files Browse the repository at this point in the history
  • Loading branch information
mickel8 committed Dec 29, 2022
1 parent adc9497 commit 8fbe885
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ The package can be installed by adding `ex_sdp` to your list of dependencies in
```elixir
def deps do
[
{:ex_sdp, "~> 0.9.0"}
{:ex_sdp, "~> 0.10.0"}
]
end
```
Expand Down
2 changes: 1 addition & 1 deletion lib/ex_sdp/attribute/fmtp.ex
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ defmodule ExSDP.Attribute.FMTP do
@spec parse(binary()) :: {:ok, t()} | {:error, reason()}
def parse(fmtp) do
with [pt_string, rest] <- String.split(fmtp, " ", parts: 2),
{:ok, pt} <- Utils.parse_payload_type(pt_string) do
{:ok, pt} <- Utils.parse_payload_type(pt_string) do
rest
|> String.split(";")
# remove leading whitespaces
Expand Down
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
defmodule ExSDP.MixProject do
use Mix.Project

@version "0.9.0"
@version "0.10.0"
@github_url "https://github.com/membraneframework/ex_sdp"

def project do
Expand Down
10 changes: 5 additions & 5 deletions test/ex_sdp/attribute/fmtp_test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,8 @@ defmodule ExSDP.Attribute.FMTPTest do

expected = %FMTP{
pt: 117,
maxplaybackrate: 16000,
maxaveragebitrate: 24000,
maxplaybackrate: 16_000,
maxaveragebitrate: 24_000,
cbr: false,
usedtx: false,
useinbandfec: false
Expand All @@ -74,14 +74,14 @@ defmodule ExSDP.Attribute.FMTPTest do
fmtp = "121 ptime=20;maxptime=60;cbr=0;sprop-maxcapturerate=16000"

expected = %FMTP{
pt: 117,
pt: 121,
ptime: 20,
maxptime: 60,
cbr: false,
sprop_maxcapturerate: 16000
sprop_maxcapturerate: 16_000
}

assert {:ok, expected} = FMTP.parse(fmtp)
assert {:ok, expected} == FMTP.parse(fmtp)
end

test "returns an error when DTMF tone is too big" do
Expand Down

0 comments on commit 8fbe885

Please sign in to comment.