Fixed errors in MATLAB client and updated tests.
This commit is contained in:
18
TestScripts/MATLAB Tests/setDREFTest.m
Normal file
18
TestScripts/MATLAB Tests/setDREFTest.m
Normal file
@@ -0,0 +1,18 @@
|
||||
function setDREFTest( )
|
||||
%SENDREADTEST Summary of this function goes here
|
||||
% Detailed explanation goes here
|
||||
addpath('../../MATLAB')
|
||||
import XPlaneConnect.*
|
||||
|
||||
DREFS = {'sim/cockpit/switches/gear_handle_status'};
|
||||
value = randi([0 10]);
|
||||
|
||||
setDREF(DREFS{1},value);
|
||||
result = getDREFs(DREFS);
|
||||
|
||||
assert(isequal(length(result),1),'setDREFTest: requestDREF unsucessful-wrong number of elements returned');
|
||||
|
||||
assert(isequal(result(1),value),'setDREFTest: DREF set unsucessful');
|
||||
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user