rob05c commented on a change in pull request #2191: revert changes that broke
perl unit tests
URL:
https://github.com/apache/incubator-trafficcontrol/pull/2191#discussion_r185237001
##########
File path: traffic_ops/app/lib/TrafficOpsRoutes.pm
##########
@@ -449,6 +449,13 @@ sub api_routes {
# -- CDNS: ROUTING
$r->get("/api/$version/cdns/routing")->over( authenticated => 1,
not_ldap => 1 )->to( 'Cdn#routing', namespace => $namespace );
+ # -- CDNS: SNAPSHOT
+ $r->get("/api/$version/cdns/:name/snapshot")->over( authenticated => 1,
not_ldap => 1 )->to( 'Topology#get_snapshot', namespace => $namespace );
+ $r->get("/api/$version/cdns/:name/snapshot/new")->over( authenticated
=> 1, not_ldap => 1 )->to( 'Topology#get_new_snapshot', namespace => $namespace
);
+ $r->put( "/api/$version/cdns/:id/snapshot" => [ id => qr/\d+/ ]
)->over( authenticated => 1, not_ldap => 1 )
+ ->to( 'Topology#SnapshotCRConfig', namespace => $namespace );
+ $r->put("/api/$version/snapshot/:cdn_name")->over( authenticated => 1,
not_ldap => 1 )->to( 'Topology#SnapshotCRConfig', namespace => $namespace );
Review comment:
Alternatively: the Go CRConfig does have unit tests, which verify creating
and getting it succeeds from database data properly, and that it contains the
proper data (which again, is more than the Perl tests do).
If you all are willing to consider the unit tests good enough for now, until
API Tests exist, we could just remove the Perl test lines right now.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services