Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libmtime
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
icon-libraries
libmtime
Commits
aeb4778d
Commit
aeb4778d
authored
11 years ago
by
Luis Kornblueh
Browse files
Options
Downloads
Patches
Plain Diff
Fixed number of arguments for newEvent in C test code.
parent
96e3e271
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
test/model_integration.c
+8
-8
8 additions, 8 deletions
test/model_integration.c
with
8 additions
and
8 deletions
test/model_integration.c
+
8
−
8
View file @
aeb4778d
...
...
@@ -82,23 +82,23 @@ main(int argc, char *argv[])
If end date is NULL, it is logically equivalent to infinity. The data-structure will not be allocated any memory and will be a NULL pointer.
*/
struct
_event
*
Ocean
=
newEvent
(
"Ocean"
,
NULL
,
NULL
,
NULL
,
"PT01M"
);
struct
_event
*
Ocean
=
newEvent
(
"Ocean"
,
NULL
,
NULL
,
NULL
,
"PT01M"
,
NULL
);
if
(
Ocean
&&
addNewEventToEventGroup
(
Ocean
,
testAllowedGroup
))
printf
(
"
\n
Created and Added event Ocean."
);
struct
_event
*
InEarth
=
newEvent
(
"InEarth"
,
NULL
,
NULL
,
"2050-01-01T00:10:00.000Z"
,
"P01Y"
);
struct
_event
*
InEarth
=
newEvent
(
"InEarth"
,
NULL
,
NULL
,
"2050-01-01T00:10:00.000Z"
,
"P01Y"
,
NULL
);
if
(
InEarth
&&
addNewEventToEventGroup
(
InEarth
,
testAllowedGroup
))
printf
(
"
\n
Created and Added event InEarth."
);
struct
_event
*
Systems
=
newEvent
(
"Systems"
,
NULL
,
"2050-01-01T00:05:00.000Z"
,
NULL
,
"PT30.000S"
);
struct
_event
*
Systems
=
newEvent
(
"Systems"
,
NULL
,
"2050-01-01T00:05:00.000Z"
,
NULL
,
"PT30.000S"
,
NULL
);
if
(
Systems
&&
addNewEventToEventGroup
(
Systems
,
testAllowedGroup
))
printf
(
"
\n
Created and Added event Systems."
);
struct
_event
*
iWillFail1
=
newEvent
(
NULL
,
"2050-01-01T00:06:00.000Z"
,
"2050-01-01T00:05:00.000Z"
,
"2050-01-01T00:10:00.000Z"
,
"PT30.000S"
);
struct
_event
*
iWillFail1
=
newEvent
(
NULL
,
"2050-01-01T00:06:00.000Z"
,
"2050-01-01T00:05:00.000Z"
,
"2050-01-01T00:10:00.000Z"
,
"PT30.000S"
,
NULL
);
if
(
!
iWillFail1
)
printf
(
"
\n
iWillFail1 event can not be created. Name can not be NULL. Name must be unique. "
);
struct
_event
*
iWillFail2
=
newEvent
(
"iWillFail2"
,
"2050-01-01T00:06:00.000Z"
,
"2050-01-01T00:05:00.000Z"
,
"2050-01-01T00:10:00.000Z"
,
NULL
);
struct
_event
*
iWillFail2
=
newEvent
(
"iWillFail2"
,
"2050-01-01T00:06:00.000Z"
,
"2050-01-01T00:05:00.000Z"
,
"2050-01-01T00:10:00.000Z"
,
NULL
,
NULL
);
if
(
!
iWillFail2
)
printf
(
"
\n
iWillFail2 event can not be created. Time step can not be null. "
);
...
...
@@ -108,16 +108,16 @@ main(int argc, char *argv[])
if
(
someGroup
)
printf
(
"
\n\n
Group Name - SomeEvent:
\n
"
);
struct
_event
*
Fisher
=
newEvent
(
"Fisher"
,
NULL
,
"2050-01-01T00:00:00.000Z"
,
NULL
,
"PT01M"
);
struct
_event
*
Fisher
=
newEvent
(
"Fisher"
,
NULL
,
"2050-01-01T00:00:00.000Z"
,
NULL
,
"PT01M"
,
NULL
);
if
(
Fisher
&&
addNewEventToEventGroup
(
Fisher
,
someGroup
))
printf
(
"
\n
Created and Added event Fisher."
);
struct
_event
*
Pearson
=
newEvent
(
"Pearson"
,
"2050-01-01T00:00:45.000Z"
,
"2050-01-01T00:05:00.000Z"
,
"2050-01-01T00:10:00.000Z"
,
"PT30.000S"
);
struct
_event
*
Pearson
=
newEvent
(
"Pearson"
,
"2050-01-01T00:00:45.000Z"
,
"2050-01-01T00:05:00.000Z"
,
"2050-01-01T00:10:00.000Z"
,
"PT30.000S"
,
NULL
);
if
(
Pearson
&&
addNewEventToEventGroup
(
Pearson
,
someGroup
))
printf
(
"
\n
Created and Added event Pearson."
);
/* Event handle and name can be different. */
struct
_event
*
Cox
=
newEvent
(
"Cox"
,
"2050-01-01T00:16:00.000Z"
,
"2050-01-01T00:05:00.000Z"
,
"2050-01-01T00:10:00.000Z"
,
"PT30.000S"
);
struct
_event
*
Cox
=
newEvent
(
"Cox"
,
"2050-01-01T00:16:00.000Z"
,
"2050-01-01T00:05:00.000Z"
,
"2050-01-01T00:10:00.000Z"
,
"PT30.000S"
,
NULL
);
if
(
Cox
&&
addNewEventToEventGroup
(
Cox
,
someGroup
))
printf
(
"
\n
Created and Added event Cox."
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment