Creating BC docker container with automatically enabled feature SalesPrices

dzouns
Member Posts: 1
in General Chat
HI!
It is possible to create BC container in which the specific features will be automatically enabled. I know I can enable them on page "Feature Management", but I need to create container during CI/CD pipeline and to run automated tests in it.
I tried to use this command for creating container:
and got message "Container features successfully created" but in client i saw that feature isn't enabled.

and then I called command:
But I got message: Unable to set feature key SalesPrices

And in feature management, SalesPricing feature was not enabled.
My another idea is to write AL code in beginning of test to enable feature, but I am not sure if that is possible.
Do anyone have some experience with it? How to test non-default enabled features in automated test?
It is possible to create BC container in which the specific features will be automatically enabled. I know I can enable them on page "Feature Management", but I need to create container during CI/CD pipeline and to run automated tests in it.
I tried to use this command for creating container:
$artifactUrl = Get-BCArtifactUrl -type OnPrem -country "w1" -version "23.2.14098.14274" -select Closest $credential = New-Object pscredential 'admin', (ConvertTo-SecureString -String 'admin' -AsPlainText -Force) $licenseFile = "-" $featureKeys = @{ "SalesPrices" = "1" } $containerName = "features" New-BcContainer ` -accept_eula ` -containerName $containerName ` -artifactUrl $artifactUrl ` -Credential $credential ` -auth UserPassword ` -updateHosts ` -restart always ` -licenseFile $licenseFile ` -shortcuts none ` -includeTestToolkit ` -imagename local17 ` -enableTaskScheduler ` -featureKeys $featureKeys
and got message "Container features successfully created" but in client i saw that feature isn't enabled.

and then I called command:
$featureKeys = @{ "SalesPrices" = "1" } $containerName = "features" Set-BcContainerFeatureKeys -containerName $containerName -featureKeys $featureKeys
But I got message: Unable to set feature key SalesPrices

And in feature management, SalesPricing feature was not enabled.
My another idea is to write AL code in beginning of test to enable feature, but I am not sure if that is possible.
Do anyone have some experience with it? How to test non-default enabled features in automated test?
0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions