Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Dóra Kocsis
dynare
Commits
ae789516
Commit
ae789516
authored
Mar 14, 2013
by
Stéphane Adjemian
Browse files
Added unitary test.
parent
7e057d17
Changes
1
Hide whitespace changes
Inline
Side-by-side
matlab/@dynDates/append.m
View file @
ae789516
...
...
@@ -96,4 +96,28 @@ end
%
$
t
(
2
)
=
dyn_assert
(
d
.
freq
,
e
.
freq
);
%
$
t
(
3
)
=
dyn_assert
(
d
.
ndat
,
e
.
ndat
);
%
$
T
=
all
(
t
);
%
@eof
:
1
\ No newline at end of file
%
@eof
:
1
%
@test
:
2
%
$
%
Define
some
dates
%
$
B1
=
'
1953
Q4
'
;
%
$
B2
=
'
1950
Q2
'
;
%
$
B3
=
'
1950
Q1
'
;
%
$
B4
=
'
1945
Q3
'
;
%
$
B5
=
'
2009
q2
'
;
%
$
%
$
%
Define
expected
results
.
%
$
e
.
time
=
[
1945
3
;
1950
1
;
1950
2
;
1953
4
;
2009
2
];
%
$
e
.
freq
=
4
;
%
$
e
.
ndat
=
5
;
%
$
%
$
%
Call
the
tested
routine
.
%
$
d
=
dynDates
(
B4
,
B3
,
B2
,
B1
);
%
$
d
=
d
.
append
(
B5
);
%
$
%
$
%
Check
the
results
.
%
$
t
(
1
)
=
dyn_assert
(
d
.
time
,
e
.
time
);
%
$
t
(
2
)
=
dyn_assert
(
d
.
freq
,
e
.
freq
);
%
$
t
(
3
)
=
dyn_assert
(
d
.
ndat
,
e
.
ndat
);
%
$
T
=
all
(
t
);
%
@eof
:
2
\ No newline at end of file
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment