ecomm/__tests__/routes/product.test.ts

12 lines
403 B
TypeScript
Raw Normal View History

2023-06-13 13:10:17 +00:00
import express from 'express';
import { authenticateToken } from '../middlewares/checkAuth.test';
import { createProduct, listProducts, getProduct } from '../controllers/ProductController.test';
const productRouter = express.Router();
productRouter.post('/', authenticateToken, createProduct)
productRouter.get('/', listProducts);
productRouter.get('/:id', getProduct);
export default productRouter;