-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make all elements optional in xml parsing for video encoder (#69)
- Loading branch information
1 parent
e119619
commit 0a68201
Showing
8 changed files
with
3,753 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
name: CI Tests | ||
|
||
on: | ||
push: | ||
branches: [ "main" ] | ||
pull_request: | ||
branches: [ "main" ] | ||
|
||
permissions: | ||
contents: read | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
build: | ||
|
||
name: Build and test | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Read .tool-versions | ||
uses: marocchino/tool-versions-action@v1 | ||
id: versions | ||
|
||
- name: Set up Elixir | ||
uses: erlef/setup-beam@v1 | ||
with: | ||
otp-version: ${{ steps.versions.outputs.erlang }} | ||
elixir-version: ${{ steps.versions.outputs.elixir }} | ||
version-type: "strict" | ||
|
||
- name: Restore dependencies cache | ||
uses: actions/cache@v4 | ||
with: | ||
path: deps | ||
key: ${{ runner.os }}-mix-${{ hashFiles('**/mix.lock') }} | ||
restore-keys: ${{ runner.os }}-mix- | ||
|
||
- name: Install dependencies | ||
run: mix deps.get | ||
|
||
- name: Run tests | ||
run: mix test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
defmodule Onvif.Factory do | ||
def device do | ||
%Onvif.Device{ | ||
address: "http://192.168.254.89", | ||
auth_type: :digest_auth, | ||
device_service_path: "/onvif/device_service", | ||
firmware_version: nil, | ||
hardware_id: "V1.0", | ||
manufacturer: "General", | ||
media_ver10_service_path: "/onvif/media_service", | ||
media_ver20_service_path: "/onvif/media2_service", | ||
model: "N864A6", | ||
ntp: "NTP", | ||
password: "admin", | ||
port: 80, | ||
scopes: [ | ||
"onvif://www.onvif.org/location/country/China", | ||
"onvif://www.onvif.org/name/General", | ||
"onvif://www.onvif.org/hardware/N864A6", | ||
"onvif://www.onvif.org/Profile/Streaming", | ||
"onvif://www.onvif.org/type/Network_Video_Transmitter", | ||
"onvif://www.onvif.org/extension/unique_identifier/1", | ||
"onvif://www.onvif.org/Profile/G", | ||
"onvif://www.onvif.org/Profile/T" | ||
], | ||
serial_number: "NV012306000836", | ||
services: [ | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver10/replay/wsdl", | ||
version: "17.06", | ||
xaddr: "http://192.168.254.89/onvif/replay_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver10/search/wsdl", | ||
version: "18.12", | ||
xaddr: "http://192.168.254.89/onvif/search_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver10/recording/wsdl", | ||
version: "18.06", | ||
xaddr: "http://192.168.254.89/onvif/recording_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver10/deviceIO/wsdl", | ||
version: "18.12", | ||
xaddr: "http://192.168.254.89/onvif/deviceIO_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver10/events/wsdl", | ||
version: "2.60", | ||
xaddr: "http://192.168.254.89/onvif/event_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver20/ptz/wsdl", | ||
version: "18.12", | ||
xaddr: "http://192.168.254.89/onvif/ptz_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver20/media/wsdl", | ||
version: "18.12", | ||
xaddr: "http://192.168.254.89/onvif/media2_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver10/media/wsdl", | ||
version: "18.06", | ||
xaddr: "http://192.168.254.89/onvif/media_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver20/imaging/wsdl", | ||
version: "18.12", | ||
xaddr: "http://192.168.254.89/onvif/imaging_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver20/analytics/wsdl", | ||
version: "18.12", | ||
xaddr: "http://192.168.254.89/onvif/analytics_service" | ||
}, | ||
%Onvif.Device.Service{ | ||
namespace: "http://www.onvif.org/ver10/device/wsdl", | ||
version: "18.12", | ||
xaddr: "http://192.168.254.89/onvif/device_service" | ||
} | ||
], | ||
time_diff_from_system_secs: 3597, | ||
username: "admin" | ||
} | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.