const express = require('express');
const { authenticateToken, authorizePermission } = require('./src/middleware/auth');

const app = express();
app.use(express.json());

// Test route
app.post('/test', authenticateToken, authorizePermission('department.create'), (req, res) => {
  res.json({ status: 'success', message: 'Permission granted' });
});

app.listen(3001, () => {
  console.log('Test server running on port 3001');
});



